summaryrefslogtreecommitdiffstats
path: root/contrib/gdb/gdb/config
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/gdb/gdb/config')
-rw-r--r--contrib/gdb/gdb/config/alpha/alpha-linux.mh7
-rw-r--r--contrib/gdb/gdb/config/alpha/alpha-linux.mt2
-rw-r--r--contrib/gdb/gdb/config/alpha/alpha-osf1.mh4
-rw-r--r--contrib/gdb/gdb/config/alpha/alpha-osf2.mh5
-rw-r--r--contrib/gdb/gdb/config/alpha/alpha-osf3.mh5
-rw-r--r--contrib/gdb/gdb/config/alpha/fbsd.mh5
-rw-r--r--contrib/gdb/gdb/config/alpha/fbsd.mt3
-rw-r--r--contrib/gdb/gdb/config/alpha/nm-fbsd.h45
-rw-r--r--contrib/gdb/gdb/config/alpha/nm-linux.h61
-rw-r--r--contrib/gdb/gdb/config/alpha/nm-osf.h30
-rw-r--r--contrib/gdb/gdb/config/alpha/nm-osf2.h29
-rw-r--r--contrib/gdb/gdb/config/alpha/nm-osf3.h27
-rw-r--r--contrib/gdb/gdb/config/alpha/tm-alphalinux.h45
-rw-r--r--contrib/gdb/gdb/config/alpha/tm-fbsd.h45
-rw-r--r--contrib/gdb/gdb/config/alpha/xm-alphalinux.h33
-rw-r--r--contrib/gdb/gdb/config/alpha/xm-alphaosf.h31
-rw-r--r--contrib/gdb/gdb/config/i386/cygwin.mh5
-rw-r--r--contrib/gdb/gdb/config/i386/embed.mt3
-rw-r--r--contrib/gdb/gdb/config/i386/fbsd.mh8
-rw-r--r--contrib/gdb/gdb/config/i386/fbsd.mt2
-rw-r--r--contrib/gdb/gdb/config/i386/go32.mh19
-rw-r--r--contrib/gdb/gdb/config/i386/go32.mt3
-rw-r--r--contrib/gdb/gdb/config/i386/i386aix.mh1
-rw-r--r--contrib/gdb/gdb/config/i386/i386bsd.mh1
-rw-r--r--contrib/gdb/gdb/config/i386/i386dgux.mh5
-rw-r--r--contrib/gdb/gdb/config/i386/i386gnu.mh4
-rw-r--r--contrib/gdb/gdb/config/i386/i386gnu.mt2
-rw-r--r--contrib/gdb/gdb/config/i386/i386lynx.mh6
-rw-r--r--contrib/gdb/gdb/config/i386/i386m3.mh3
-rw-r--r--contrib/gdb/gdb/config/i386/i386mach.mh1
-rw-r--r--contrib/gdb/gdb/config/i386/i386mk.mh2
-rw-r--r--contrib/gdb/gdb/config/i386/i386sco.mh1
-rw-r--r--contrib/gdb/gdb/config/i386/i386sco4.mh1
-rw-r--r--contrib/gdb/gdb/config/i386/i386sco5.mh3
-rw-r--r--contrib/gdb/gdb/config/i386/i386sol2.mh5
-rw-r--r--contrib/gdb/gdb/config/i386/i386sol2.mt2
-rw-r--r--contrib/gdb/gdb/config/i386/i386v.mh1
-rw-r--r--contrib/gdb/gdb/config/i386/i386v32.mh1
-rw-r--r--contrib/gdb/gdb/config/i386/i386v4.mh5
-rw-r--r--contrib/gdb/gdb/config/i386/i386v42mp.mh11
-rw-r--r--contrib/gdb/gdb/config/i386/linux.mh13
-rw-r--r--contrib/gdb/gdb/config/i386/linux.mt5
-rw-r--r--contrib/gdb/gdb/config/i386/nbsd.mh11
-rw-r--r--contrib/gdb/gdb/config/i386/nbsd.mt4
-rw-r--r--contrib/gdb/gdb/config/i386/nbsdelf.mh4
-rw-r--r--contrib/gdb/gdb/config/i386/nbsdelf.mt5
-rw-r--r--contrib/gdb/gdb/config/i386/ncr3000.mh4
-rw-r--r--contrib/gdb/gdb/config/i386/ncr3000.mt2
-rw-r--r--contrib/gdb/gdb/config/i386/nm-cygwin.h38
-rw-r--r--contrib/gdb/gdb/config/i386/nm-fbsd.h110
-rw-r--r--contrib/gdb/gdb/config/i386/nm-gnu.h27
-rw-r--r--contrib/gdb/gdb/config/i386/nm-go32.h38
-rw-r--r--contrib/gdb/gdb/config/i386/nm-i386.h120
-rw-r--r--contrib/gdb/gdb/config/i386/nm-i386aix.h27
-rw-r--r--contrib/gdb/gdb/config/i386/nm-i386bsd.h33
-rw-r--r--contrib/gdb/gdb/config/i386/nm-i386lynx.h25
-rw-r--r--contrib/gdb/gdb/config/i386/nm-i386mach.h32
-rw-r--r--contrib/gdb/gdb/config/i386/nm-i386sco.h33
-rw-r--r--contrib/gdb/gdb/config/i386/nm-i386sco4.h31
-rw-r--r--contrib/gdb/gdb/config/i386/nm-i386sco5.h29
-rw-r--r--contrib/gdb/gdb/config/i386/nm-i386sol2.h69
-rw-r--r--contrib/gdb/gdb/config/i386/nm-i386v.h33
-rw-r--r--contrib/gdb/gdb/config/i386/nm-i386v4.h28
-rw-r--r--contrib/gdb/gdb/config/i386/nm-i386v42mp.h29
-rw-r--r--contrib/gdb/gdb/config/i386/nm-linux.h126
-rw-r--r--contrib/gdb/gdb/config/i386/nm-m3.h25
-rw-r--r--contrib/gdb/gdb/config/i386/nm-nbsd.h35
-rw-r--r--contrib/gdb/gdb/config/i386/nm-nbsdelf.h28
-rw-r--r--contrib/gdb/gdb/config/i386/nm-obsd.h110
-rw-r--r--contrib/gdb/gdb/config/i386/nm-ptx4.h34
-rw-r--r--contrib/gdb/gdb/config/i386/nm-symmetry.h34
-rw-r--r--contrib/gdb/gdb/config/i386/nm-x86-64.h90
-rw-r--r--contrib/gdb/gdb/config/i386/obsd.mh7
-rw-r--r--contrib/gdb/gdb/config/i386/obsd.mt3
-rw-r--r--contrib/gdb/gdb/config/i386/ptx.mh2
-rw-r--r--contrib/gdb/gdb/config/i386/ptx4.mh3
-rw-r--r--contrib/gdb/gdb/config/i386/symmetry.mh1
-rw-r--r--contrib/gdb/gdb/config/i386/tm-cygwin.h134
-rw-r--r--contrib/gdb/gdb/config/i386/tm-fbsd.h99
-rw-r--r--contrib/gdb/gdb/config/i386/tm-go32.h68
-rw-r--r--contrib/gdb/gdb/config/i386/tm-i386.h372
-rw-r--r--contrib/gdb/gdb/config/i386/tm-i386aix.h71
-rw-r--r--contrib/gdb/gdb/config/i386/tm-i386bsd.h30
-rw-r--r--contrib/gdb/gdb/config/i386/tm-i386gnu.h68
-rw-r--r--contrib/gdb/gdb/config/i386/tm-i386lynx.h27
-rw-r--r--contrib/gdb/gdb/config/i386/tm-i386m3.h32
-rw-r--r--contrib/gdb/gdb/config/i386/tm-i386mk.h39
-rw-r--r--contrib/gdb/gdb/config/i386/tm-i386nw.h36
-rw-r--r--contrib/gdb/gdb/config/i386/tm-i386os9k.h34
-rw-r--r--contrib/gdb/gdb/config/i386/tm-i386sco5.h35
-rw-r--r--contrib/gdb/gdb/config/i386/tm-i386sol2.h67
-rw-r--r--contrib/gdb/gdb/config/i386/tm-i386v.h159
-rw-r--r--contrib/gdb/gdb/config/i386/tm-i386v4.h41
-rw-r--r--contrib/gdb/gdb/config/i386/tm-i386v42mp.h95
-rw-r--r--contrib/gdb/gdb/config/i386/tm-linux.h132
-rw-r--r--contrib/gdb/gdb/config/i386/tm-nbsd.h68
-rw-r--r--contrib/gdb/gdb/config/i386/tm-nbsdelf.h28
-rw-r--r--contrib/gdb/gdb/config/i386/tm-obsd.h77
-rw-r--r--contrib/gdb/gdb/config/i386/tm-ptx.h53
-rw-r--r--contrib/gdb/gdb/config/i386/tm-ptx4.h28
-rw-r--r--contrib/gdb/gdb/config/i386/tm-symmetry.h54
-rw-r--r--contrib/gdb/gdb/config/i386/tm-vxworks.h28
-rw-r--r--contrib/gdb/gdb/config/i386/vxworks.mt3
-rw-r--r--contrib/gdb/gdb/config/i386/x86-64linux.mh11
-rw-r--r--contrib/gdb/gdb/config/i386/x86-64linux.mt5
-rw-r--r--contrib/gdb/gdb/config/i386/xm-cygwin.h38
-rw-r--r--contrib/gdb/gdb/config/i386/xm-go32.h41
-rw-r--r--contrib/gdb/gdb/config/i386/xm-i386.h30
-rw-r--r--contrib/gdb/gdb/config/i386/xm-i386aix.h32
-rw-r--r--contrib/gdb/gdb/config/i386/xm-i386bsd.h32
-rw-r--r--contrib/gdb/gdb/config/i386/xm-i386gnu.h30
-rw-r--r--contrib/gdb/gdb/config/i386/xm-i386m3.h30
-rw-r--r--contrib/gdb/gdb/config/i386/xm-i386mach.h32
-rw-r--r--contrib/gdb/gdb/config/i386/xm-i386mk.h27
-rw-r--r--contrib/gdb/gdb/config/i386/xm-i386sco.h30
-rw-r--r--contrib/gdb/gdb/config/i386/xm-i386v.h48
-rw-r--r--contrib/gdb/gdb/config/i386/xm-i386v32.h25
-rw-r--r--contrib/gdb/gdb/config/i386/xm-i386v4.h27
-rw-r--r--contrib/gdb/gdb/config/i386/xm-nbsd.h29
-rw-r--r--contrib/gdb/gdb/config/i386/xm-ptx.h31
-rw-r--r--contrib/gdb/gdb/config/i386/xm-ptx4.h30
-rw-r--r--contrib/gdb/gdb/config/i386/xm-symmetry.h30
-rw-r--r--contrib/gdb/gdb/config/ia64/aix.mh8
-rw-r--r--contrib/gdb/gdb/config/ia64/aix.mt4
-rw-r--r--contrib/gdb/gdb/config/ia64/linux.mh10
-rw-r--r--contrib/gdb/gdb/config/ia64/linux.mt6
-rw-r--r--contrib/gdb/gdb/config/ia64/nm-aix.h37
-rw-r--r--contrib/gdb/gdb/config/ia64/nm-linux.h79
-rw-r--r--contrib/gdb/gdb/config/ia64/tm-aix.h32
-rw-r--r--contrib/gdb/gdb/config/ia64/tm-ia64.h252
-rw-r--r--contrib/gdb/gdb/config/ia64/tm-linux.h34
-rw-r--r--contrib/gdb/gdb/config/ia64/xm-aix.h28
-rw-r--r--contrib/gdb/gdb/config/ia64/xm-linux.h28
-rw-r--r--contrib/gdb/gdb/config/nm-linux.h74
-rw-r--r--contrib/gdb/gdb/config/none/nm-none.h19
-rw-r--r--contrib/gdb/gdb/config/none/none.mh5
-rw-r--r--contrib/gdb/gdb/config/none/none.mt4
-rw-r--r--contrib/gdb/gdb/config/none/tm-none.h24
-rw-r--r--contrib/gdb/gdb/config/none/xm-none.h19
-rw-r--r--contrib/gdb/gdb/config/tm-linux.h42
-rw-r--r--contrib/gdb/gdb/config/tm-vxworks.h23
141 files changed, 3310 insertions, 1574 deletions
diff --git a/contrib/gdb/gdb/config/alpha/alpha-linux.mh b/contrib/gdb/gdb/config/alpha/alpha-linux.mh
index aa4a069..39f3532 100644
--- a/contrib/gdb/gdb/config/alpha/alpha-linux.mh
+++ b/contrib/gdb/gdb/config/alpha/alpha-linux.mh
@@ -1,9 +1,10 @@
# Host: Little-endian Alpha running Linux
-XDEPFILES= ser-tcp.o
XM_FILE= xm-alphalinux.h
NAT_FILE= nm-linux.h
-NATDEPFILES= infptrace.o inftarg.o corelow.o core-regset.o alpha-nat.o \
- fork-child.o solib.o
+NATDEPFILES= infptrace.o inftarg.o corelow.o alpha-nat.o linux-proc.o \
+ fork-child.o proc-service.o thread-db.o lin-lwp.o gcore.o
+
+LOADLIBES = -ldl -rdynamic
MMALLOC =
MMALLOC_CFLAGS = -DNO_MMALLOC
diff --git a/contrib/gdb/gdb/config/alpha/alpha-linux.mt b/contrib/gdb/gdb/config/alpha/alpha-linux.mt
index 7789252..dd1c8e2 100644
--- a/contrib/gdb/gdb/config/alpha/alpha-linux.mt
+++ b/contrib/gdb/gdb/config/alpha/alpha-linux.mt
@@ -1,3 +1,3 @@
# Target: Little-endian Alpha
-TDEPFILES= alpha-tdep.o
+TDEPFILES= alpha-tdep.o solib.o solib-svr4.o solib-legacy.o
TM_FILE= tm-alphalinux.h
diff --git a/contrib/gdb/gdb/config/alpha/alpha-osf1.mh b/contrib/gdb/gdb/config/alpha/alpha-osf1.mh
index 6ed0f95..6d53b44 100644
--- a/contrib/gdb/gdb/config/alpha/alpha-osf1.mh
+++ b/contrib/gdb/gdb/config/alpha/alpha-osf1.mh
@@ -1,5 +1,5 @@
# Host: Little-endian Alpha running OSF/1-1.x
-XDEPFILES=
XM_FILE= xm-alphaosf.h
NAT_FILE= nm-osf.h
-NATDEPFILES= infptrace.o inftarg.o corelow.o alpha-nat.o fork-child.o osfsolib.o
+NATDEPFILES= infptrace.o inftarg.o corelow.o alpha-nat.o fork-child.o \
+ solib-osf.o solib.o
diff --git a/contrib/gdb/gdb/config/alpha/alpha-osf2.mh b/contrib/gdb/gdb/config/alpha/alpha-osf2.mh
index 569b6fd..b853ebb 100644
--- a/contrib/gdb/gdb/config/alpha/alpha-osf2.mh
+++ b/contrib/gdb/gdb/config/alpha/alpha-osf2.mh
@@ -1,5 +1,6 @@
# Host: Little-endian Alpha running OSF/1-2.x using procfs
-XDEPFILES=
XM_FILE= xm-alphaosf.h
NAT_FILE= nm-osf2.h
-NATDEPFILES= infptrace.o inftarg.o corelow.o alpha-nat.o fork-child.o osfsolib.o procfs.o
+NATDEPFILES= infptrace.o inftarg.o corelow.o alpha-nat.o fork-child.o \
+ solib-osf.o solib.o procfs.o proc-api.o proc-events.o proc-flags.o \
+ proc-why.o
diff --git a/contrib/gdb/gdb/config/alpha/alpha-osf3.mh b/contrib/gdb/gdb/config/alpha/alpha-osf3.mh
index 4997531..f074444 100644
--- a/contrib/gdb/gdb/config/alpha/alpha-osf3.mh
+++ b/contrib/gdb/gdb/config/alpha/alpha-osf3.mh
@@ -1,5 +1,6 @@
# Host: Little-endian Alpha running OSF/1-3.x and higher using procfs
-XDEPFILES=
XM_FILE= xm-alphaosf.h
NAT_FILE= nm-osf3.h
-NATDEPFILES= infptrace.o inftarg.o corelow.o alpha-nat.o fork-child.o osfsolib.o procfs.o
+NATDEPFILES= infptrace.o inftarg.o corelow.o alpha-nat.o fork-child.o \
+ solib-osf.o solib.o procfs.o proc-api.o proc-events.o proc-flags.o \
+ proc-why.o
diff --git a/contrib/gdb/gdb/config/alpha/fbsd.mh b/contrib/gdb/gdb/config/alpha/fbsd.mh
new file mode 100644
index 0000000..7e036e4
--- /dev/null
+++ b/contrib/gdb/gdb/config/alpha/fbsd.mh
@@ -0,0 +1,5 @@
+# Host: FreeBSD/Alpha
+NATDEPFILES= fork-child.o infptrace.o inftarg.o \
+ solib.o solib-svr4.o solib-legacy.o \
+ corelow.o core-regset.o alphabsd-nat.o
+NAT_FILE= nm-fbsd.h
diff --git a/contrib/gdb/gdb/config/alpha/fbsd.mt b/contrib/gdb/gdb/config/alpha/fbsd.mt
new file mode 100644
index 0000000..48e54fa
--- /dev/null
+++ b/contrib/gdb/gdb/config/alpha/fbsd.mt
@@ -0,0 +1,3 @@
+# Target: FreeBSD/Alpha
+TDEPFILES= alpha-tdep.o alphafbsd-tdep.o
+TM_FILE= tm-fbsd.h
diff --git a/contrib/gdb/gdb/config/alpha/nm-fbsd.h b/contrib/gdb/gdb/config/alpha/nm-fbsd.h
new file mode 100644
index 0000000..f3fb129
--- /dev/null
+++ b/contrib/gdb/gdb/config/alpha/nm-fbsd.h
@@ -0,0 +1,45 @@
+/* Native-dependent definitions for FreeBSD/Alpha.
+ Copyright 1986, 1987, 1989, 1992, 1996, 2000
+ Free Software Foundation, Inc.
+
+ This file is part of GDB.
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
+
+#ifndef NM_FBSD_H
+#define NM_FBSD_H
+
+/* Type of the third argument to the `ptrace' system call. */
+#define PTRACE_ARG3_TYPE caddr_t
+
+/* Override copies of {fetch,store}_inferior_registers in `infptrace.c'. */
+#define FETCH_INFERIOR_REGISTERS
+
+/* We can attach and detach. */
+#define ATTACH_DETACH
+
+/* The Alpha does not step over a breakpoint. */
+#define CANNOT_STEP_BREAKPOINT
+
+
+/* Shared library support. */
+
+#define SVR4_SHARED_LIBS
+
+#include "solib.h" /* Support for shared libraries. */
+#include "elf/common.h" /* Additional ELF shared library info. */
+
+#endif /* NM_FBSD_H */
diff --git a/contrib/gdb/gdb/config/alpha/nm-linux.h b/contrib/gdb/gdb/config/alpha/nm-linux.h
index eedb1a9..5d5e945 100644
--- a/contrib/gdb/gdb/config/alpha/nm-linux.h
+++ b/contrib/gdb/gdb/config/alpha/nm-linux.h
@@ -1,21 +1,29 @@
-/* Native definitions for alpha running Linux.
- Copyright (C) 1993, 1994 Free Software Foundation, Inc.
+/* Native definitions for alpha running GNU/Linux.
-This file is part of GDB.
+ Copyright 1993, 1994, 1996, 1998, 2000, 2001, 2002 Free Software
+ Foundation, Inc.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This file is part of GDB.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is 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.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
+
+#ifndef NM_LINUX_H
+#define NM_LINUX_H
+
+#include "nm-linux.h"
/* Figure out where the longjmp will land. We expect that we have just entered
longjmp and haven't yet setup the stack frame, so the args are still in the
@@ -24,16 +32,14 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */
This routine returns true on success */
#define GET_LONGJMP_TARGET(ADDR) get_longjmp_target(ADDR)
-extern int
-get_longjmp_target PARAMS ((CORE_ADDR *));
-
-/* Tell gdb that we can attach and detach other processes */
-#define ATTACH_DETACH
+extern int get_longjmp_target (CORE_ADDR *);
/* ptrace register ``addresses'' are absolute. */
#define U_REGS_OFFSET 0
+/* FIXME: This is probably true, or should be, on all GNU/Linux ports.
+ IA64? Sparc64? */
#define PTRACE_ARG3_TYPE long
/* ptrace transfers longs, the ptrace man page is lying. */
@@ -44,23 +50,12 @@ get_longjmp_target PARAMS ((CORE_ADDR *));
#define CANNOT_STEP_BREAKPOINT
-/* Linux has shared libraries. */
+/* GNU/Linux has shared libraries. */
#define GDB_TARGET_HAS_SHARED_LIBS
-/* Support for shared libraries. */
-
-#include "solib.h"
-
-#ifdef __ELF__
-#define SVR4_SHARED_LIBS
-#define TARGET_ELF64
-#endif
-
-/* This is a lie. It's actually in stdio.h. */
-
-#define PSIGNAL_IN_SIGNAL_H
-
/* Given a pointer to either a gregset_t or fpregset_t, return a
pointer to the first register. */
#define ALPHA_REGSET_BASE(regsetp) ((long *) (regsetp))
+
+#endif /* NM_LINUX_H */
diff --git a/contrib/gdb/gdb/config/alpha/nm-osf.h b/contrib/gdb/gdb/config/alpha/nm-osf.h
index e06140d..5fc99e4 100644
--- a/contrib/gdb/gdb/config/alpha/nm-osf.h
+++ b/contrib/gdb/gdb/config/alpha/nm-osf.h
@@ -1,21 +1,22 @@
/* Native definitions for alpha running OSF/1.
- Copyright (C) 1993, 1994 Free Software Foundation, Inc.
+ Copyright 1993, 1994, 1995, 1998, 2000 Free Software Foundation, Inc.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
/* Figure out where the longjmp will land. We expect that we have just entered
longjmp and haven't yet setup the stack frame, so the args are still in the
@@ -24,8 +25,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
This routine returns true on success */
#define GET_LONGJMP_TARGET(ADDR) get_longjmp_target(ADDR)
-extern int
-get_longjmp_target PARAMS ((CORE_ADDR *));
+extern int get_longjmp_target (CORE_ADDR *);
/* ptrace register ``addresses'' are absolute. */
diff --git a/contrib/gdb/gdb/config/alpha/nm-osf2.h b/contrib/gdb/gdb/config/alpha/nm-osf2.h
index 01725ef..4b225af 100644
--- a/contrib/gdb/gdb/config/alpha/nm-osf2.h
+++ b/contrib/gdb/gdb/config/alpha/nm-osf2.h
@@ -1,21 +1,22 @@
/* Native definitions for alpha running OSF/1-2.x, using procfs.
- Copyright (C) 1995 Free Software Foundation, Inc.
+ Copyright 1995, 1996, 2000 Free Software Foundation, Inc.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
/* Get generic OSF/1 definitions. */
#include "alpha/nm-osf.h"
@@ -44,7 +45,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/* Return sizeof user struct to callers in less machine dependent routines */
#define KERNEL_U_SIZE kernel_u_size()
-extern int kernel_u_size PARAMS ((void));
+extern int kernel_u_size (void);
/* poll() doesn't seem to work properly for /proc in this version of the OS.
If we only specify POLLPRI, things hang. It seems to get better when we set
diff --git a/contrib/gdb/gdb/config/alpha/nm-osf3.h b/contrib/gdb/gdb/config/alpha/nm-osf3.h
index a1871a6..e2818d5 100644
--- a/contrib/gdb/gdb/config/alpha/nm-osf3.h
+++ b/contrib/gdb/gdb/config/alpha/nm-osf3.h
@@ -1,21 +1,22 @@
/* Native definitions for alpha running OSF/1-3.x and higher, using procfs.
- Copyright (C) 1995 Free Software Foundation, Inc.
+ Copyright 1995 Free Software Foundation, Inc.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
/* OSF/1-3.x fixes some OSF/1-2.x procfs peculiarities and adds
a new one. */
diff --git a/contrib/gdb/gdb/config/alpha/tm-alphalinux.h b/contrib/gdb/gdb/config/alpha/tm-alphalinux.h
index d836a70..23592aa 100644
--- a/contrib/gdb/gdb/config/alpha/tm-alphalinux.h
+++ b/contrib/gdb/gdb/config/alpha/tm-alphalinux.h
@@ -1,22 +1,26 @@
-/* Definitions to make GDB run on an Alpha box under Linux. The
- definitions here are used when the _target_ system is running Linux.
- Copyright 1996 Free Software Foundation, Inc.
+/* Definitions to make GDB run on an Alpha box under GNU/Linux. The
+ definitions here are used when the _target_ system is running
+ GNU/Linux.
-This file is part of GDB.
+ Copyright 1996, 1998, 1999, 2000, 2002 Free Software Foundation,
+ Inc.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This file is part of GDB.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is 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.
-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 program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
#ifndef TM_LINUXALPHA_H
#define TM_LINUXALPHA_H
@@ -25,7 +29,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/* Are we currently handling a signal ? */
-extern long alpha_linux_sigtramp_offset PARAMS ((CORE_ADDR));
+extern long alpha_linux_sigtramp_offset (CORE_ADDR);
#undef IN_SIGTRAMP
#define IN_SIGTRAMP(pc, name) (alpha_linux_sigtramp_offset (pc) >= 0)
@@ -37,7 +41,7 @@ extern long alpha_linux_sigtramp_offset PARAMS ((CORE_ADDR));
/* 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
- on Linux and most implementations. */
+ on GNU/Linux and most implementations. */
#undef START_INFERIOR_TRAPS_EXPECTED
#define START_INFERIOR_TRAPS_EXPECTED 2
@@ -68,13 +72,12 @@ extern long alpha_linux_sigtramp_offset PARAMS ((CORE_ADDR));
/* If FRAME refers to a sigtramp frame, return the address of the next frame.
- Under Linux, sigtramp handlers have dynamically generated procedure
- descriptors that make this hack unnecessary. */
+ Under GNU/Linux, sigtramp handlers have dynamically generated
+ procedure descriptors that make this hack unnecessary. */
#undef FRAME_PAST_SIGTRAMP_FRAME
#define FRAME_PAST_SIGTRAMP_FRAME(frame, pc) (0)
-/* We need this for the SOLIB_TRAMPOLINE stuff. */
-#include "tm-sysv4.h"
+#include "tm-linux.h"
#endif /* TM_LINUXALPHA_H */
diff --git a/contrib/gdb/gdb/config/alpha/tm-fbsd.h b/contrib/gdb/gdb/config/alpha/tm-fbsd.h
new file mode 100644
index 0000000..00d3c27
--- /dev/null
+++ b/contrib/gdb/gdb/config/alpha/tm-fbsd.h
@@ -0,0 +1,45 @@
+/* Target-dependent definitions for FreeBSD/Alpha.
+ Copyright 2000, 2001 Free Software Foundation, Inc.
+
+ This file is part of GDB.
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
+
+#ifndef TM_FBSD_H
+#define TM_FBSD_H
+
+#include "alpha/tm-alpha.h"
+
+/* FreeBSD uses the old gcc convention for struct returns. */
+
+#undef USE_STRUCT_CONVENTION
+#define USE_STRUCT_CONVENTION(gcc_p, type) \
+ alphafbsd_use_struct_convention (gcc_p, type)
+
+/* FreeBSD doesn't mark the outermost frame. While some FreeBSD/Alpha
+ releases include (a minimal amount of) debugging info in its
+ startup code (crt1.o), the safest thing is to consider the user
+ code entry point as the outermost frame. */
+#define FRAME_CHAIN_VALID(chain, thisframe) \
+ func_frame_chain_valid(chain, thisframe)
+
+/* Number of traps that happen between exec'ing the shell to run an
+ inferior, and when we finally get to the inferior code. The
+ default is right for FreeBSD. */
+
+#undef START_INFERIOR_TRAPS_EXPECTED
+
+#endif /* TM_FBSD_H */
diff --git a/contrib/gdb/gdb/config/alpha/xm-alphalinux.h b/contrib/gdb/gdb/config/alpha/xm-alphalinux.h
index a7aeab0..f1bc14d 100644
--- a/contrib/gdb/gdb/config/alpha/xm-alphalinux.h
+++ b/contrib/gdb/gdb/config/alpha/xm-alphalinux.h
@@ -1,29 +1,26 @@
-/* Host definitions for GDB running on an Alpha under Linux
- Copyright (C) 1996 Free Software Foundation, Inc.
+/* Host definitions for GDB running on an Alpha under GNU/Linux.
-This file is part of GDB.
+ Copyright 1996, 2001, 2002 Free Software Foundation, Inc.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This file is part of GDB.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is 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.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */
+ 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.
-#if !defined (HOST_BYTE_ORDER)
-#define HOST_BYTE_ORDER LITTLE_ENDIAN
-#endif
+ 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. */
/* The alpha has no siginterrupt routine. */
#define NO_SIGINTERRUPT
#define HAVE_TERMIOS
-#define HAVE_SIGSETMASK 1
#define USG
diff --git a/contrib/gdb/gdb/config/alpha/xm-alphaosf.h b/contrib/gdb/gdb/config/alpha/xm-alphaosf.h
index 40b7fe0..67d3cc4 100644
--- a/contrib/gdb/gdb/config/alpha/xm-alphaosf.h
+++ b/contrib/gdb/gdb/config/alpha/xm-alphaosf.h
@@ -1,25 +1,22 @@
/* Host definitions for GDB running on an alpha under OSF/1
- Copyright (C) 1992, 1993 Free Software Foundation, Inc.
+ Copyright 1992, 1993, 1996 Free Software Foundation, Inc.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */
-
-#if !defined (HOST_BYTE_ORDER)
-#define HOST_BYTE_ORDER LITTLE_ENDIAN
-#endif
+ 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. */
/* The alpha has no siginterrupt routine. */
#define NO_SIGINTERRUPT
diff --git a/contrib/gdb/gdb/config/i386/cygwin.mh b/contrib/gdb/gdb/config/i386/cygwin.mh
index d93acb6..ce4656f 100644
--- a/contrib/gdb/gdb/config/i386/cygwin.mh
+++ b/contrib/gdb/gdb/config/i386/cygwin.mh
@@ -1,6 +1,5 @@
MH_CFLAGS=
XM_FILE=xm-cygwin.h
-XDEPFILES=ser-tcp.o
-NATDEPFILES= win32-nat.o
-NAT_FILE=../nm-empty.h
+NATDEPFILES= i386-nat.o win32-nat.o corelow.o
+NAT_FILE=nm-cygwin.h
XM_CLIBS=
diff --git a/contrib/gdb/gdb/config/i386/embed.mt b/contrib/gdb/gdb/config/i386/embed.mt
new file mode 100644
index 0000000..6925a83
--- /dev/null
+++ b/contrib/gdb/gdb/config/i386/embed.mt
@@ -0,0 +1,3 @@
+# Target: Embedded Intel 386
+TDEPFILES= i386-tdep.o i387-tdep.o
+TM_FILE= tm-i386.h
diff --git a/contrib/gdb/gdb/config/i386/fbsd.mh b/contrib/gdb/gdb/config/i386/fbsd.mh
index 499ed48..364dfa6 100644
--- a/contrib/gdb/gdb/config/i386/fbsd.mh
+++ b/contrib/gdb/gdb/config/i386/fbsd.mh
@@ -1,5 +1,7 @@
# Host: Intel 386 running FreeBSD
-XDEPFILES= ser-tcp.o
-NATDEPFILES= fork-child.o infptrace.o inftarg.o corelow.o core-aout.o i386b-nat.o
-XM_FILE= xm-i386bsd.h
+
+XM_FILE= xm-i386.h
+
NAT_FILE= nm-fbsd.h
+# NOTE: Do not spread NATDEPFILES over several lines - it hurts BSD make.
+NATDEPFILES= fork-child.o infptrace.o inftarg.o solib.o solib-svr4.o solib-legacy.o corelow.o core-aout.o core-regset.o i386-nat.o i387-nat.o i386bsd-nat.o i386fbsd-nat.o
diff --git a/contrib/gdb/gdb/config/i386/fbsd.mt b/contrib/gdb/gdb/config/i386/fbsd.mt
index e644f1c..7a95e00 100644
--- a/contrib/gdb/gdb/config/i386/fbsd.mt
+++ b/contrib/gdb/gdb/config/i386/fbsd.mt
@@ -1,3 +1,3 @@
# Target: Intel 386 running FreeBSD
-TDEPFILES= i386-tdep.o i387-tdep.o solib.o
+TDEPFILES= i386-tdep.o i387-tdep.o i386bsd-tdep.o
TM_FILE= tm-fbsd.h
diff --git a/contrib/gdb/gdb/config/i386/go32.mh b/contrib/gdb/gdb/config/i386/go32.mh
index 311ee1c..3d3bdfd 100644
--- a/contrib/gdb/gdb/config/i386/go32.mh
+++ b/contrib/gdb/gdb/config/i386/go32.mh
@@ -1,8 +1,17 @@
-MH_CFLAGS=-D__GO32__ -D__MSDOS__
-XDEPFILES= go32-xdep.o
+# Host: Intel x86 running DJGPP
+# we don't need mmalloc on DJGPP
+MH_CFLAGS= -DNO_MMALLOC
+MMALLOC=
+MMALLOC_CFLAGS=
+
XM_FILE= xm-go32.h
-HOST_IPC=-DDOS_IPC
-SER_HARDWIRE= ser-go32.o
-CC=i386-go32-gcc -O2 -fno-omit-frame-pointer
+
+NAT_FILE= nm-go32.h
+NATDEPFILES= go32-nat.o i386-nat.o i387-nat.o
+
+TERMCAP=
+HOST_IPC=
+CC= gcc
+XM_CLIBS= -ldbg
diff --git a/contrib/gdb/gdb/config/i386/go32.mt b/contrib/gdb/gdb/config/i386/go32.mt
new file mode 100644
index 0000000..9b82c64
--- /dev/null
+++ b/contrib/gdb/gdb/config/i386/go32.mt
@@ -0,0 +1,3 @@
+# Target: Intel 386 running DJGPP
+TDEPFILES= i386-tdep.o i387-tdep.o
+TM_FILE= tm-go32.h
diff --git a/contrib/gdb/gdb/config/i386/i386aix.mh b/contrib/gdb/gdb/config/i386/i386aix.mh
index cea05f0..af88729 100644
--- a/contrib/gdb/gdb/config/i386/i386aix.mh
+++ b/contrib/gdb/gdb/config/i386/i386aix.mh
@@ -1,7 +1,6 @@
# Host: IBM PS/2 (i386) running AIX PS/2
XM_FILE= xm-i386aix.h
-XDEPFILES=
NAT_FILE= nm-i386aix.h
NATDEPFILES= infptrace.o inftarg.o fork-child.o corelow.o i386aix-nat.o
diff --git a/contrib/gdb/gdb/config/i386/i386bsd.mh b/contrib/gdb/gdb/config/i386/i386bsd.mh
index f95c6ed..01457d4 100644
--- a/contrib/gdb/gdb/config/i386/i386bsd.mh
+++ b/contrib/gdb/gdb/config/i386/i386bsd.mh
@@ -1,7 +1,6 @@
# Host: Intel 386 running 386BSD
XM_FILE= xm-i386bsd.h
-XDEPFILES=
NAT_FILE= nm-i386bsd.h
NATDEPFILES= fork-child.o infptrace.o inftarg.o corelow.o core-aout.o i386b-nat.o
diff --git a/contrib/gdb/gdb/config/i386/i386dgux.mh b/contrib/gdb/gdb/config/i386/i386dgux.mh
index e05ebcd..fd7f56c 100644
--- a/contrib/gdb/gdb/config/i386/i386dgux.mh
+++ b/contrib/gdb/gdb/config/i386/i386dgux.mh
@@ -1,9 +1,10 @@
# Host: Intel 386 running DGUX, cloned from SVR4
XM_FILE= xm-i386v4.h
-XDEPFILES= ser-tcp.o
# for network communication
XM_CLIBS= -lsocket -lnsl
NAT_FILE= nm-i386v4.h
-NATDEPFILES= corelow.o core-regset.o solib.o procfs.o fork-child.o i386v4-nat.o
+NATDEPFILES= corelow.o core-regset.o fork-child.o i386v4-nat.o \
+ solib.o solib-svr4.o solib-legacy.o \
+ procfs.o proc-api.o proc-events.o proc-flags.o proc-why.o
diff --git a/contrib/gdb/gdb/config/i386/i386gnu.mh b/contrib/gdb/gdb/config/i386/i386gnu.mh
index 4ceac7e..252b2e5 100644
--- a/contrib/gdb/gdb/config/i386/i386gnu.mh
+++ b/contrib/gdb/gdb/config/i386/i386gnu.mh
@@ -1,6 +1,5 @@
# Host: Intel 386 running the GNU Hurd
-XDEPFILES= i387-tdep.o
-NATDEPFILES= i386gnu-nat.o gnu-nat.o fork-child.o solib.o corelow.o notify_S.o process_reply_S.o msg_reply_S.o msg_U.o exc_request_U.o exc_request_S.o
+NATDEPFILES= i386gnu-nat.o i387-nat.o gnu-nat.o fork-child.o solib.o solib-svr4.o solib-legacy.o corelow.o notify_S.o process_reply_S.o msg_reply_S.o msg_U.o exc_request_U.o exc_request_S.o
XM_FILE= xm-i386gnu.h
NAT_FILE= nm-gnu.h
MH_CFLAGS = -D_GNU_SOURCE
@@ -12,7 +11,6 @@ XM_CLIBS = -lshouldbeinlibc
msg-MIGUFLAGS = -D'MSG_IMPORTS=waittime 1000;'
# ick
-MIG = mig
MIGCOM = $(MIG) -cc cat - /dev/null
# Reply servers need special massaging of the code mig generates, to make
diff --git a/contrib/gdb/gdb/config/i386/i386gnu.mt b/contrib/gdb/gdb/config/i386/i386gnu.mt
index 64fb018..e08e2a2 100644
--- a/contrib/gdb/gdb/config/i386/i386gnu.mt
+++ b/contrib/gdb/gdb/config/i386/i386gnu.mt
@@ -1,3 +1,3 @@
# Target: Intel 386/elf/GNU Hurd
-TDEPFILES= i386-tdep.o
+TDEPFILES= i386-tdep.o i387-tdep.o
TM_FILE= tm-i386gnu.h
diff --git a/contrib/gdb/gdb/config/i386/i386lynx.mh b/contrib/gdb/gdb/config/i386/i386lynx.mh
index 9cb086f..0552b4d 100644
--- a/contrib/gdb/gdb/config/i386/i386lynx.mh
+++ b/contrib/gdb/gdb/config/i386/i386lynx.mh
@@ -1,11 +1,9 @@
# Host: Intel 386 running LynxOS
-XM_FILE= xm-i386lynx.h
XM_CLIBS= -lbsd
-XDEPFILES= ser-tcp.o
NAT_FILE= nm-i386lynx.h
NATDEPFILES= fork-child.o infptrace.o inftarg.o corelow.o lynx-nat.o
-GDBSERVER_LIBS= -lbsd
-GDBSERVER_DEPFILES= low-lynx.o
+## OBSOLETE ## GDBSERVER_LIBS= -lbsd
+## OBSOLETE ## GDBSERVER_DEPFILES= low-lynx.o
diff --git a/contrib/gdb/gdb/config/i386/i386m3.mh b/contrib/gdb/gdb/config/i386/i386m3.mh
index 0a83ebf7..41ea30c 100644
--- a/contrib/gdb/gdb/config/i386/i386m3.mh
+++ b/contrib/gdb/gdb/config/i386/i386m3.mh
@@ -1,7 +1,6 @@
# Host: Intel 386 running Mach3
-XDEPFILES= i387-tdep.o core-aout.o
-NATDEPFILES= i386m3-nat.o m3-nat.o fork-child.o
+NATDEPFILES= i386m3-nat.o m3-nat.o fork-child.o i387-tdep.o core-aout.o
NAT_CLIBS= -lmachid -lnetname -lmach
XM_FILE= xm-i386m3.h
NAT_FILE= nm-m3.h
diff --git a/contrib/gdb/gdb/config/i386/i386mach.mh b/contrib/gdb/gdb/config/i386/i386mach.mh
index 44766c5..90dbdf4 100644
--- a/contrib/gdb/gdb/config/i386/i386mach.mh
+++ b/contrib/gdb/gdb/config/i386/i386mach.mh
@@ -4,7 +4,6 @@
# host and native, not target). Once we get the mach3 stuff working,
# I think it can go away.
-XDEPFILES=
XM_FILE= xm-i386mach.h
NAT_FILE= nm-i386mach.h
NATDEPFILES= infptrace.o inftarg.o fork-child.o i386mach-nat.o
diff --git a/contrib/gdb/gdb/config/i386/i386mk.mh b/contrib/gdb/gdb/config/i386/i386mk.mh
index 849677c..0c119be 100644
--- a/contrib/gdb/gdb/config/i386/i386mk.mh
+++ b/contrib/gdb/gdb/config/i386/i386mk.mh
@@ -1,4 +1,4 @@
# Host: Intel 386 running Mach3 with OSF 1/MK
-XDEPFILES= os-mach3.o i386mach3-xdep.o i387-tdep.o
+NATDEPFILES= os-mach3.o i386mach3-xdep.o i387-tdep.o
XM_FILE= xm-i386osf1mk.h
diff --git a/contrib/gdb/gdb/config/i386/i386sco.mh b/contrib/gdb/gdb/config/i386/i386sco.mh
index 69076b5..d039944 100644
--- a/contrib/gdb/gdb/config/i386/i386sco.mh
+++ b/contrib/gdb/gdb/config/i386/i386sco.mh
@@ -1,7 +1,6 @@
# Host: Intel 386 running SCO Unix (pre-SVR4)
XM_FILE= xm-i386sco.h
-XDEPFILES=
XM_CLIBS= -lPW
NAT_FILE= nm-i386sco.h
diff --git a/contrib/gdb/gdb/config/i386/i386sco4.mh b/contrib/gdb/gdb/config/i386/i386sco4.mh
index a13f993..2507e07 100644
--- a/contrib/gdb/gdb/config/i386/i386sco4.mh
+++ b/contrib/gdb/gdb/config/i386/i386sco4.mh
@@ -1,7 +1,6 @@
# Host: Intel 386 running SCO Unix 3.2v4
XM_FILE= xm-i386sco.h
-XDEPFILES=
XM_CLIBS= -lPW
NAT_FILE= nm-i386sco4.h
diff --git a/contrib/gdb/gdb/config/i386/i386sco5.mh b/contrib/gdb/gdb/config/i386/i386sco5.mh
index 3bea87a..7b8b827 100644
--- a/contrib/gdb/gdb/config/i386/i386sco5.mh
+++ b/contrib/gdb/gdb/config/i386/i386sco5.mh
@@ -8,10 +8,9 @@ XM_FILE= xm-i386sco.h
# runtime, but all come with the development system, so we always
# have socket(), gethostbyname(), and friends.
#
-XDEPFILES= ser-tcp.o
XM_CLIBS= -lPW -lsocket
NAT_FILE= nm-i386sco5.h
NATDEPFILES= infptrace.o inftarg.o fork-child.o corefile.o core-aout.o \
- corelow.o i386v-nat.o solib.o
+ corelow.o i386v-nat.o solib.o solib-svr4.o solib-legacy.o
diff --git a/contrib/gdb/gdb/config/i386/i386sol2.mh b/contrib/gdb/gdb/config/i386/i386sol2.mh
index ff24294..ab7f474 100644
--- a/contrib/gdb/gdb/config/i386/i386sol2.mh
+++ b/contrib/gdb/gdb/config/i386/i386sol2.mh
@@ -1,7 +1,8 @@
# Host: Intel 386 running Solaris 2 (SVR4)
XM_FILE= xm-i386v4.h
-XDEPFILES=
+XM_CLIBS= -lsocket -lnsl
NAT_FILE= nm-i386sol2.h
-NATDEPFILES= core-regset.o procfs.o fork-child.o i386v4-nat.o corelow.o
+NATDEPFILES= core-regset.o fork-child.o i386v4-nat.o i387-nat.o corelow.o \
+ procfs.o proc-api.o proc-events.o proc-flags.o proc-why.o gcore.o
diff --git a/contrib/gdb/gdb/config/i386/i386sol2.mt b/contrib/gdb/gdb/config/i386/i386sol2.mt
index 80b576f..86d93a3 100644
--- a/contrib/gdb/gdb/config/i386/i386sol2.mt
+++ b/contrib/gdb/gdb/config/i386/i386sol2.mt
@@ -1,3 +1,3 @@
# Target: Intel 386 running SVR4
-TDEPFILES= i386-tdep.o i387-tdep.o solib.o
+TDEPFILES= i386-tdep.o i387-tdep.o solib.o solib-svr4.o solib-legacy.o
TM_FILE= tm-i386sol2.h
diff --git a/contrib/gdb/gdb/config/i386/i386v.mh b/contrib/gdb/gdb/config/i386/i386v.mh
index d67a30f..7f0ea6e 100644
--- a/contrib/gdb/gdb/config/i386/i386v.mh
+++ b/contrib/gdb/gdb/config/i386/i386v.mh
@@ -1,7 +1,6 @@
# Host: Intel 386 running System V
XM_FILE= xm-i386v.h
-XDEPFILES=
XM_CLIBS= -lPW
NAT_FILE= nm-i386v.h
diff --git a/contrib/gdb/gdb/config/i386/i386v32.mh b/contrib/gdb/gdb/config/i386/i386v32.mh
index 5b4175f..f394372 100644
--- a/contrib/gdb/gdb/config/i386/i386v32.mh
+++ b/contrib/gdb/gdb/config/i386/i386v32.mh
@@ -1,7 +1,6 @@
# Host: Intel 386 running System V release 3.2
XM_FILE= xm-i386v32.h
-XDEPFILES=
XM_CLIBS= -lPW
NAT_FILE= nm-i386v.h
diff --git a/contrib/gdb/gdb/config/i386/i386v4.mh b/contrib/gdb/gdb/config/i386/i386v4.mh
index 4653887..a3952bc 100644
--- a/contrib/gdb/gdb/config/i386/i386v4.mh
+++ b/contrib/gdb/gdb/config/i386/i386v4.mh
@@ -1,9 +1,10 @@
# Host: Intel 386 running SVR4
XM_FILE= xm-i386v4.h
-XDEPFILES=
# for network communication
XM_CLIBS= -lsocket -lnsl
NAT_FILE= nm-i386v4.h
-NATDEPFILES= corelow.o core-regset.o solib.o procfs.o fork-child.o i386v4-nat.o
+NATDEPFILES= corelow.o core-regset.o fork-child.o i386v4-nat.o \
+ solib.o solib-svr4.o solib-legacy.o \
+ procfs.o proc-api.o proc-events.o proc-flags.o proc-why.o
diff --git a/contrib/gdb/gdb/config/i386/i386v42mp.mh b/contrib/gdb/gdb/config/i386/i386v42mp.mh
index 94b6c06..007a8bf 100644
--- a/contrib/gdb/gdb/config/i386/i386v42mp.mh
+++ b/contrib/gdb/gdb/config/i386/i386v42mp.mh
@@ -1,11 +1,18 @@
# Host: Intel 386 running SVR4
XM_FILE= xm-i386v4.h
-XDEPFILES=
# for network communication
XM_CLIBS= -lsocket -lnsl
# we don't want nm-i386v4.h since that defines LOSING_POLL which isn't
# appropriate for i386v42mp
NAT_FILE= nm-i386v42mp.h
-NATDEPFILES= corelow.o core-regset.o solib.o procfs.o fork-child.o i386v4-nat.o
+
+# NATDEPFILES must remain entirely on one line. When building a cross
+# debugger, configure will cause this line to be commented out in the
+# Makefile. Many non-GNU versions of make don't permit the use of a
+# continuation character (backslash) to extend a commented line. As a
+# consequence, make considers subsequent tab-indented lines to be
+# some sort of error.
+NATDEPFILES= corelow.o core-regset.o fork-child.o i386v4-nat.o i387-nat.o solib.o solib-svr4.o solib-legacy.o procfs.o proc-api.o proc-events.o proc-flags.o proc-why.o uw-thread.o
+
diff --git a/contrib/gdb/gdb/config/i386/linux.mh b/contrib/gdb/gdb/config/i386/linux.mh
index 30de91d..cc645e95 100644
--- a/contrib/gdb/gdb/config/i386/linux.mh
+++ b/contrib/gdb/gdb/config/i386/linux.mh
@@ -1,7 +1,12 @@
-# Host: Intel 386 running GNU/Linux
+# Host: Intel 386 running GNU/Linux.
-XM_FILE= xm-linux.h
-XDEPFILES= ser-tcp.o
+XM_FILE= xm-i386.h
NAT_FILE= nm-linux.h
-NATDEPFILES= infptrace.o solib.o inftarg.o fork-child.o corelow.o core-aout.o core-regset.o i386v-nat.o i386v4-nat.o
+NATDEPFILES= infptrace.o inftarg.o fork-child.o corelow.o linux-proc.o \
+ core-aout.o i386-nat.o i386-linux-nat.o i387-nat.o \
+ proc-service.o thread-db.o lin-lwp.o linux-proc.o gcore.o
+
+# The dynamically loaded libthread_db needs access to symbols in the
+# gdb executable.
+LOADLIBES = -ldl -rdynamic
diff --git a/contrib/gdb/gdb/config/i386/linux.mt b/contrib/gdb/gdb/config/i386/linux.mt
index 66cc97d..43bc2d26 100644
--- a/contrib/gdb/gdb/config/i386/linux.mt
+++ b/contrib/gdb/gdb/config/i386/linux.mt
@@ -1,5 +1,6 @@
# Target: Intel 386 running GNU/Linux
-TDEPFILES= i386-tdep.o i387-tdep.o
+TDEPFILES= i386-tdep.o i386-linux-tdep.o i387-tdep.o \
+ solib.o solib-svr4.o solib-legacy.o
TM_FILE= tm-linux.h
-GDBSERVER_DEPFILES= low-linux.o
+GDBSERVER_DEPFILES = linux-low.o linux-i386-low.o reg-i386.o
diff --git a/contrib/gdb/gdb/config/i386/nbsd.mh b/contrib/gdb/gdb/config/i386/nbsd.mh
index c76b897..66f4561 100644
--- a/contrib/gdb/gdb/config/i386/nbsd.mh
+++ b/contrib/gdb/gdb/config/i386/nbsd.mh
@@ -1,5 +1,12 @@
# Host: Intel 386 running NetBSD
-XDEPFILES= ser-tcp.o
-NATDEPFILES= fork-child.o infptrace.o inftarg.o corelow.o i386b-nat.o
+
+# NATDEPFILES must remain entirely on one line for *BSD. When
+# building a cross debugger, configure will cause this line to be
+# commented out in the Makefile. BSD make doesn't permit the use of a
+# continuation character (backslash) to extend a commented line. As a
+# consequence, BSD make considers subsequent tab-indented lines to be
+# "unassociated shell commands".
+NATDEPFILES= fork-child.o infptrace.o inftarg.o corelow.o i387-nat.o i386bsd-nat.o i386nbsd-nat.o solib.o solib-sunos.o
+
XM_FILE= xm-nbsd.h
NAT_FILE= nm-nbsd.h
diff --git a/contrib/gdb/gdb/config/i386/nbsd.mt b/contrib/gdb/gdb/config/i386/nbsd.mt
index 7570850..8ab606e 100644
--- a/contrib/gdb/gdb/config/i386/nbsd.mt
+++ b/contrib/gdb/gdb/config/i386/nbsd.mt
@@ -1,3 +1,5 @@
# Target: Intel 386 running NetBSD
-TDEPFILES= i386-tdep.o i387-tdep.o solib.o
+TDEPFILES= i386-tdep.o i387-tdep.o i386bsd-tdep.o i386nbsd-tdep.o
TM_FILE= tm-nbsd.h
+
+## OBSOLETE ## GDBSERVER_DEPFILES= low-nbsd.o
diff --git a/contrib/gdb/gdb/config/i386/nbsdelf.mh b/contrib/gdb/gdb/config/i386/nbsdelf.mh
new file mode 100644
index 0000000..f25a406
--- /dev/null
+++ b/contrib/gdb/gdb/config/i386/nbsdelf.mh
@@ -0,0 +1,4 @@
+# Host: Intel 386 running NetBSD
+NATDEPFILES= fork-child.o infptrace.o inftarg.o corelow.o i387-nat.o i386bsd-nat.o i386nbsd-nat.o solib.o solib-svr4.o solib-legacy.o
+XM_FILE= xm-nbsd.h
+NAT_FILE= nm-nbsdelf.h
diff --git a/contrib/gdb/gdb/config/i386/nbsdelf.mt b/contrib/gdb/gdb/config/i386/nbsdelf.mt
new file mode 100644
index 0000000..ab173d3
--- /dev/null
+++ b/contrib/gdb/gdb/config/i386/nbsdelf.mt
@@ -0,0 +1,5 @@
+# Target: Intel 386 running NetBSD
+TDEPFILES= i386-tdep.o i387-tdep.o i386bsd-tdep.o
+TM_FILE= tm-nbsdelf.h
+
+## OBSOLETE ## GDBSERVER_DEPFILES= low-nbsd.o
diff --git a/contrib/gdb/gdb/config/i386/ncr3000.mh b/contrib/gdb/gdb/config/i386/ncr3000.mh
index 4f60756..4e669ba 100644
--- a/contrib/gdb/gdb/config/i386/ncr3000.mh
+++ b/contrib/gdb/gdb/config/i386/ncr3000.mh
@@ -10,7 +10,7 @@ CC = /usr/ccs/ATT/cc
CFLAGS =
XM_FILE= xm-i386v4.h
-XDEPFILES=
NAT_FILE= nm-i386v4.h
-NATDEPFILES= corelow.o core-regset.o procfs.o fork-child.o i386v4-nat.o
+NATDEPFILES= corelow.o core-regset.o fork-child.o i386v4-nat.o procfs.o \
+ proc-api.o proc-events.o proc-flags.o proc-why.o
diff --git a/contrib/gdb/gdb/config/i386/ncr3000.mt b/contrib/gdb/gdb/config/i386/ncr3000.mt
index 0bbf9b36..11bc474 100644
--- a/contrib/gdb/gdb/config/i386/ncr3000.mt
+++ b/contrib/gdb/gdb/config/i386/ncr3000.mt
@@ -1,3 +1,3 @@
# Target: Intel 386 running SVR4
-TDEPFILES= i386-tdep.o i387-tdep.o solib.o
+TDEPFILES= i386-tdep.o i387-tdep.o solib.o solib-svr4.o solib-legacy.o
TM_FILE= tm-i386v4.h
diff --git a/contrib/gdb/gdb/config/i386/nm-cygwin.h b/contrib/gdb/gdb/config/i386/nm-cygwin.h
new file mode 100644
index 0000000..b5e4890
--- /dev/null
+++ b/contrib/gdb/gdb/config/i386/nm-cygwin.h
@@ -0,0 +1,38 @@
+/* Native definitions for Intel x86 running CYGWIN.
+ Copyright (C) 2002 Free Software Foundation, Inc.
+
+ This file is part of GDB.
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
+
+#define NO_PTRACE_H
+
+#define I386_USE_GENERIC_WATCHPOINTS
+
+#include "i386/nm-i386.h"
+
+/* Support for hardware-assisted breakpoints and watchpoints. */
+
+#define I386_DR_LOW_SET_CONTROL(VAL) cygwin_set_dr7 (VAL)
+extern void cygwin_set_dr7 (unsigned);
+
+#define I386_DR_LOW_SET_ADDR(N,ADDR) cygwin_set_dr (N,ADDR)
+extern void cygwin_set_dr (int, CORE_ADDR);
+
+#define I386_DR_LOW_RESET_ADDR(N)
+
+#define I386_DR_LOW_GET_STATUS() cygwin_get_dr6 ()
+extern unsigned cygwin_get_dr6 (void);
diff --git a/contrib/gdb/gdb/config/i386/nm-fbsd.h b/contrib/gdb/gdb/config/i386/nm-fbsd.h
index 727623c..939b880 100644
--- a/contrib/gdb/gdb/config/i386/nm-fbsd.h
+++ b/contrib/gdb/gdb/config/i386/nm-fbsd.h
@@ -1,27 +1,71 @@
-/* Native-dependent definitions for Intel 386 running BSD Unix, for GDB.
- Copyright 1986, 1987, 1989, 1992, 1996 Free Software Foundation, Inc.
+/* Native-dependent definitions for FreeBSD/i386.
+ Copyright 1986, 1987, 1989, 1992, 1994, 1996, 1997, 2000, 2001
+ Free Software Foundation, Inc.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
-#ifndef NM_FREEBSD_H
-#define NM_FREEBSD_H
+#ifndef NM_FBSD_H
+#define NM_FBSD_H
-/* Be shared lib aware */
-#include "solib.h"
+#ifdef HAVE_PT_GETDBREGS
+#define I386_USE_GENERIC_WATCHPOINTS
+#endif
+
+#include "i386/nm-i386.h"
+
+/* Provide access to the i386 hardware debugging registers. */
+
+#define I386_DR_LOW_SET_CONTROL(control) \
+ i386bsd_dr_set_control (control)
+extern void i386bsd_dr_set_control (unsigned long control);
+
+#define I386_DR_LOW_SET_ADDR(regnum, addr) \
+ i386bsd_dr_set_addr (regnum, addr)
+extern void i386bsd_dr_set_addr (int regnum, CORE_ADDR addr);
+
+#define I386_DR_LOW_RESET_ADDR(regnum) \
+ i386bsd_dr_reset_addr (regnum)
+extern void i386bsd_dr_reset_addr (int regnum);
+
+#define I386_DR_LOW_GET_STATUS() \
+ i386bsd_dr_get_status ()
+extern unsigned long i386bsd_dr_get_status (void);
+
+
+/* Type of the third argument to the `ptrace' system call. */
+#define PTRACE_ARG3_TYPE caddr_t
+
+/* Override copies of {fetch,store}_inferior_registers in `infptrace.c'. */
+#define FETCH_INFERIOR_REGISTERS
+
+/* Override child_resume in `infptrace.c' to work around a kernel bug. */
+#define CHILD_RESUME
+
+/* We can attach and detach. */
+#define ATTACH_DETACH
+
+
+/* Support for the user struct. */
+
+/* Return the size of the user struct. */
+
+#define KERNEL_U_SIZE kernel_u_size ()
+extern int kernel_u_size (void);
/* This is the amount to subtract from u.u_ar0
to get the offset in the core file of the register values. */
@@ -30,14 +74,27 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define KERNEL_U_ADDR USRSTACK
#define REGISTER_U_ADDR(addr, blockend, regno) \
- (addr) = i386_register_u_addr ((blockend),(regno));
+ (addr) = register_u_addr ((blockend), (regno))
+extern CORE_ADDR register_u_addr (CORE_ADDR blockend, int regno);
+
-extern int
-i386_register_u_addr PARAMS ((int, int));
+/* Shared library support. */
-#define PTRACE_ARG3_TYPE char*
+/* The FreeBSD <link.h> uses the same condition to distinguish ELF
+ from a.out. ELF implies SVR4 shared libraries. */
+#if (defined (FREEBSD_ELF) || defined (__ELF__)) && !defined (FREEBSD_AOUT)
+#define SVR4_SHARED_LIBS
+#endif
+
+#include "solib.h" /* Support for shared libraries. */
+#ifdef SVR4_SHARED_LIBS
+#include "elf/common.h" /* Additional ELF shared library info. */
+#endif
+
+#ifndef SVR4_SHARED_LIBS
+
+/* Make structure definitions match up with those expected in `solib.c'. */
-/* make structure definitions match up with those expected in solib.c */
#define link_object sod
#define lo_name sod_name
#define lo_library sod_library
@@ -90,9 +147,6 @@ i386_register_u_addr PARAMS ((int, int));
#define ld_un d_un
#define ld_2 d_sdt
-/* Return sizeof user struct to callers in less machine dependent routines */
-
-#define KERNEL_U_SIZE kernel_u_size()
-extern int kernel_u_size PARAMS ((void));
+#endif /* !SVR4_SHARED_LIBS */
-#endif /* NM_FREEBSD_H */
+#endif /* NM_FBSD_H */
diff --git a/contrib/gdb/gdb/config/i386/nm-gnu.h b/contrib/gdb/gdb/config/i386/nm-gnu.h
index 95f25a5..fa6d829 100644
--- a/contrib/gdb/gdb/config/i386/nm-gnu.h
+++ b/contrib/gdb/gdb/config/i386/nm-gnu.h
@@ -1,21 +1,22 @@
/* Native-dependent definitions for Intel 386 running the GNU Hurd
- Copyright 1994, 1995 Free Software Foundation, Inc.
+ Copyright 1994, 1995, 1996 Free Software Foundation, Inc.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
/* Include the generic hurd definitions. */
diff --git a/contrib/gdb/gdb/config/i386/nm-go32.h b/contrib/gdb/gdb/config/i386/nm-go32.h
new file mode 100644
index 0000000..70b1907
--- /dev/null
+++ b/contrib/gdb/gdb/config/i386/nm-go32.h
@@ -0,0 +1,38 @@
+/* Native definitions for Intel x86 running DJGPP.
+ Copyright (C) 1997, 1998, 1999, 2001 Free Software Foundation, Inc.
+
+ This file is part of GDB.
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
+
+#define NO_PTRACE_H
+
+#define I386_USE_GENERIC_WATCHPOINTS
+
+#include "i386/nm-i386.h"
+
+/* Support for hardware-assisted breakpoints and watchpoints. */
+
+#define I386_DR_LOW_SET_CONTROL(VAL) go32_set_dr7 (VAL)
+extern void go32_set_dr7 (unsigned);
+
+#define I386_DR_LOW_SET_ADDR(N,ADDR) go32_set_dr (N,ADDR)
+extern void go32_set_dr (int, CORE_ADDR);
+
+#define I386_DR_LOW_RESET_ADDR(N)
+
+#define I386_DR_LOW_GET_STATUS() go32_get_dr6 ()
+extern unsigned go32_get_dr6 (void);
diff --git a/contrib/gdb/gdb/config/i386/nm-i386.h b/contrib/gdb/gdb/config/i386/nm-i386.h
new file mode 100644
index 0000000..500bf7b
--- /dev/null
+++ b/contrib/gdb/gdb/config/i386/nm-i386.h
@@ -0,0 +1,120 @@
+/* Native macro definitions for GDB on an Intel i[3456]86.
+ Copyright 2001 Free Software Foundation, Inc.
+
+ This file is part of GDB.
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
+
+#ifndef NM_I386_H
+#define NM_I386_H 1
+
+/* Hardware-assisted breakpoints and watchpoints. */
+
+/* Targets should define this to use the generic x86 watchpoint support. */
+#ifdef I386_USE_GENERIC_WATCHPOINTS
+
+#ifndef TARGET_HAS_HARDWARE_WATCHPOINTS
+#define TARGET_HAS_HARDWARE_WATCHPOINTS
+#endif
+
+/* Clear the reference counts and forget everything we knew about DRi. */
+extern void i386_cleanup_dregs (void);
+
+/* Insert a watchpoint to watch a memory region which starts at
+ address ADDR and whose length is LEN bytes. Watch memory accesses
+ of the type TYPE. Return 0 on success, -1 on failure. */
+extern int i386_insert_watchpoint (CORE_ADDR addr, int len, int type);
+
+/* Remove a watchpoint that watched the memory region which starts at
+ address ADDR, whose length is LEN bytes, and for accesses of the
+ type TYPE. Return 0 on success, -1 on failure. */
+extern int i386_remove_watchpoint (CORE_ADDR addr, int len, int type);
+
+/* Return non-zero if we can watch a memory region that starts at
+ address ADDR and whose length is LEN bytes. */
+extern int i386_region_ok_for_watchpoint (CORE_ADDR addr, int len);
+
+/* Return non-zero if the inferior has some break/watchpoint that
+ triggered. */
+extern int i386_stopped_by_hwbp (void);
+
+/* If the inferior has some break/watchpoint that triggered, return
+ the address associated with that break/watchpoint. Otherwise,
+ return zero. */
+extern CORE_ADDR i386_stopped_data_address (void);
+
+/* Insert a hardware-assisted breakpoint at address ADDR. SHADOW is
+ unused. Return 0 on success, EBUSY on failure. */
+extern int i386_insert_hw_breakpoint (CORE_ADDR addr, void *shadow);
+
+/* Remove a hardware-assisted breakpoint at address ADDR. SHADOW is
+ unused. Return 0 on success, -1 on failure. */
+extern int i386_remove_hw_breakpoint (CORE_ADDR addr, void *shadow);
+
+/* Returns the number of hardware watchpoints of type TYPE that we can
+ set. Value is positive if we can set CNT watchpoints, zero if
+ setting watchpoints of type TYPE is not supported, and negative if
+ CNT is more than the maximum number of watchpoints of type TYPE
+ that we can support. TYPE is one of bp_hardware_watchpoint,
+ bp_read_watchpoint, bp_write_watchpoint, or bp_hardware_breakpoint.
+ CNT is the number of such watchpoints used so far (including this
+ one). OTHERTYPE is non-zero if other types of watchpoints are
+ currently enabled.
+
+ We always return 1 here because we don't have enough information
+ about possible overlap of addresses that they want to watch. As an
+ extreme example, consider the case where all the watchpoints watch
+ the same address and the same region length: then we can handle a
+ virtually unlimited number of watchpoints, due to debug register
+ sharing implemented via reference counts in i386-nat.c. */
+
+#define TARGET_CAN_USE_HARDWARE_WATCHPOINT(type, cnt, ot) 1
+
+/* Returns non-zero if we can use hardware watchpoints to watch a
+ region whose address is ADDR and whose length is LEN. */
+
+#define TARGET_REGION_OK_FOR_HW_WATCHPOINT(addr, len) \
+ i386_region_ok_for_watchpoint (addr, len)
+
+/* After a watchpoint trap, the PC points to the instruction after the
+ one that caused the trap. Therefore we don't need to step over it.
+ But we do need to reset the status register to avoid another trap. */
+
+#define HAVE_CONTINUABLE_WATCHPOINT
+
+#define STOPPED_BY_WATCHPOINT(W) (i386_stopped_data_address () != 0)
+
+#define target_stopped_data_address() i386_stopped_data_address ()
+
+/* Use these macros for watchpoint insertion/removal. */
+
+#define target_insert_watchpoint(addr, len, type) \
+ i386_insert_watchpoint (addr, len, type)
+
+#define target_remove_watchpoint(addr, len, type) \
+ i386_remove_watchpoint (addr, len, type)
+
+#define target_insert_hw_breakpoint(addr, shadow) \
+ i386_insert_hw_breakpoint (addr, shadow)
+
+#define target_remove_hw_breakpoint(addr, shadow) \
+ i386_remove_hw_breakpoint (addr, shadow)
+
+#define DECR_PC_AFTER_HW_BREAK 0
+
+#endif /* I386_USE_GENERIC_WATCHPOINTS */
+
+#endif /* NM_I386_H */
diff --git a/contrib/gdb/gdb/config/i386/nm-i386aix.h b/contrib/gdb/gdb/config/i386/nm-i386aix.h
index 4240393..4a6ffc1 100644
--- a/contrib/gdb/gdb/config/i386/nm-i386aix.h
+++ b/contrib/gdb/gdb/config/i386/nm-i386aix.h
@@ -1,25 +1,26 @@
/* Native support for i386 aix ps/2.
Copyright 1986, 1987, 1989, 1992, 1993 Free Software Foundation, Inc.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
/*
* Changes for IBM AIX PS/2 by Minh Tran-Le (tranle@intellicorp.com)
- * Revision: 5-May-93 00:11:35
+ * Revision: 5-May-93 00:11:35
*/
#ifndef NM_I386AIX_H
diff --git a/contrib/gdb/gdb/config/i386/nm-i386bsd.h b/contrib/gdb/gdb/config/i386/nm-i386bsd.h
index 7366f2d..0015af2 100644
--- a/contrib/gdb/gdb/config/i386/nm-i386bsd.h
+++ b/contrib/gdb/gdb/config/i386/nm-i386bsd.h
@@ -1,21 +1,23 @@
/* Native-dependent definitions for Intel 386 running BSD Unix, for GDB.
- Copyright 1986, 1987, 1989, 1992 Free Software Foundation, Inc.
+ Copyright 1986, 1987, 1989, 1992, 1993, 2000
+ Free Software Foundation, Inc.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
#ifndef NM_I386BSD_H
#define NM_I386BSD_H
@@ -26,13 +28,12 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include <machine/vmparam.h>
#define KERNEL_U_ADDR USRSTACK
-#undef FLOAT_INFO /* No float info yet */
+#undef FLOAT_INFO /* No float info yet */
#define REGISTER_U_ADDR(addr, blockend, regno) \
(addr) = i386_register_u_addr ((blockend),(regno));
-extern int
-i386_register_u_addr PARAMS ((int, int));
+extern int i386_register_u_addr (int, int);
#define PTRACE_ARG3_TYPE char*
diff --git a/contrib/gdb/gdb/config/i386/nm-i386lynx.h b/contrib/gdb/gdb/config/i386/nm-i386lynx.h
index e29821f..5d0d41d 100644
--- a/contrib/gdb/gdb/config/i386/nm-i386lynx.h
+++ b/contrib/gdb/gdb/config/i386/nm-i386lynx.h
@@ -1,21 +1,22 @@
/* Native-dependent definitions for Intel 386 running LynxOS.
Copyright 1993 Free Software Foundation, Inc.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
#ifndef NM_I386LYNX_H
#define NM_I386LYNX_H
diff --git a/contrib/gdb/gdb/config/i386/nm-i386mach.h b/contrib/gdb/gdb/config/i386/nm-i386mach.h
index f01d2b1..ef10a28 100644
--- a/contrib/gdb/gdb/config/i386/nm-i386mach.h
+++ b/contrib/gdb/gdb/config/i386/nm-i386mach.h
@@ -1,24 +1,28 @@
/* Native definitions for Mach on an Intel 386
- Copyright (C) 1986, 1987, 1989, 1991, 1992 Free Software Foundation, Inc.
+ Copyright 1986, 1987, 1989, 1991, 1992, 1996
+ Free Software Foundation, Inc.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
+
+#include "regcache.h"
/* Do implement the attach and detach commands. */
-/* #define ATTACH_DETACH 1 */
+/* #define ATTACH_DETACH 1 */
/* Override copies of {fetch,store}_inferior_registers in infptrace.c. */
#define FETCH_INFERIOR_REGISTERS
diff --git a/contrib/gdb/gdb/config/i386/nm-i386sco.h b/contrib/gdb/gdb/config/i386/nm-i386sco.h
index 33ab6de..b467761 100644
--- a/contrib/gdb/gdb/config/i386/nm-i386sco.h
+++ b/contrib/gdb/gdb/config/i386/nm-i386sco.h
@@ -1,22 +1,24 @@
/* Native support for i386.
- Copyright 1986, 1987, 1989, 1992 Free Software Foundation, Inc.
+ Copyright 1986, 1987, 1989, 1992, 1994, 1998, 2000
+ Free Software Foundation, Inc.
Changes for 80386 by Pace Willisson (pace@prep.ai.mit.edu), July 1988.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
#if 0
/* code to execute to print interesting information about the
@@ -27,13 +29,12 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
do this unless we *know* we aren't cross-debugging. FIXME.
*/
#define FLOAT_INFO { i386_float_info (); }
-#endif /*0*/
+#endif /*0 */
#define REGISTER_U_ADDR(addr, blockend, regno) \
(addr) = i386_register_u_addr ((blockend),(regno));
-extern int
-i386_register_u_addr PARAMS ((int, int));
+extern int i386_register_u_addr (int, int);
/* When calling functions on SCO, sometimes we get an error writing some
of the segment registers. This would appear to be a kernel
diff --git a/contrib/gdb/gdb/config/i386/nm-i386sco4.h b/contrib/gdb/gdb/config/i386/nm-i386sco4.h
index 41daef5..6947f3f 100644
--- a/contrib/gdb/gdb/config/i386/nm-i386sco4.h
+++ b/contrib/gdb/gdb/config/i386/nm-i386sco4.h
@@ -3,21 +3,22 @@
Contributed by Cygnus Support. By Ian Lance Taylor
<ian@cygnus.com> based on work by Martin Walker <maw@netcom.com>.
-This file is part of GDB.
-
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
-
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ This file 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. */
/* SCO 3.2v4 is actually just like SCO 3.2v2, except that it
additionally supports attaching to a process. */
diff --git a/contrib/gdb/gdb/config/i386/nm-i386sco5.h b/contrib/gdb/gdb/config/i386/nm-i386sco5.h
index 10e749b..db2880c 100644
--- a/contrib/gdb/gdb/config/i386/nm-i386sco5.h
+++ b/contrib/gdb/gdb/config/i386/nm-i386sco5.h
@@ -5,28 +5,29 @@
work by Ian Lance Taylor <ian@cygnus.com> and
Martin Walker <maw@netcom.com>.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
/* Basically, its a lot like the older versions ... */
#include "i386/nm-i386sco.h"
/* ... but it can do a lot of SVR4 type stuff too. */
#define SVR4_SHARED_LIBS
-#include "solib.h" /* Pick up shared library support */
+#include "solib.h" /* Pick up shared library support */
#define ATTACH_DETACH
@@ -35,5 +36,3 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */
#define PTRACE_ATTACH 10
#define PTRACE_DETACH 11
-
-
diff --git a/contrib/gdb/gdb/config/i386/nm-i386sol2.h b/contrib/gdb/gdb/config/i386/nm-i386sol2.h
index 2ae966c..0e6b3ef 100644
--- a/contrib/gdb/gdb/config/i386/nm-i386sol2.h
+++ b/contrib/gdb/gdb/config/i386/nm-i386sol2.h
@@ -1,35 +1,60 @@
/* Native support for i386 running Solaris 2.
- Copyright 1998 Free Software Foundation, Inc.
+ Copyright 1998, 1999, 2000 Free Software Foundation, Inc.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
#include "nm-sysv4.h"
-#ifdef HAVE_THREAD_DB_LIB
+#ifdef NEW_PROC_API /* Solaris 6 and above can do HW watchpoints */
-#ifdef __STDC__
-struct objfile;
-#endif
+#define TARGET_HAS_HARDWARE_WATCHPOINTS
-#define target_new_objfile(OBJFILE) sol_thread_new_objfile (OBJFILE)
+/* The man page for proc4 on solaris 6 and 7 says that the system
+ can support "thousands" of hardware watchpoints, but gives no
+ method for finding out how many. So just tell GDB 'yes'. */
+#define TARGET_CAN_USE_HARDWARE_WATCHPOINT(TYPE, CNT, OT) 1
-void sol_thread_new_objfile PARAMS ((struct objfile *objfile));
+/* When a hardware watchpoint fires off the PC will be left at the
+ instruction following the one which caused the watchpoint.
+ It will *NOT* be necessary for GDB to step over the watchpoint. */
+#define HAVE_CONTINUABLE_WATCHPOINT
-#define FIND_NEW_THREADS sol_find_new_threads
-void sol_find_new_threads PARAMS ((void));
+/* Solaris x86 2.6 and 2.7 targets have a kernel bug when stepping
+ over an instruction that causes a page fault without triggering
+ a hardware watchpoint. The kernel properly notices that it shouldn't
+ stop, because the hardware watchpoint is not triggered, but it forgets
+ the step request and continues the program normally.
+ Work around the problem by removing hardware watchpoints if a step is
+ requested, GDB will check for a hardware watchpoint trigger after the
+ step anyway. */
+#define CANNOT_STEP_HW_WATCHPOINTS
-#endif
+extern int procfs_stopped_by_watchpoint (ptid_t);
+#define STOPPED_BY_WATCHPOINT(W) \
+ procfs_stopped_by_watchpoint(inferior_ptid)
+
+/* Use these macros for watchpoint insertion/deletion. */
+/* type can be 0: write watch, 1: read watch, 2: access watch (read/write) */
+
+extern int procfs_set_watchpoint (ptid_t, CORE_ADDR, int, int, int);
+#define target_insert_watchpoint(ADDR, LEN, TYPE) \
+ procfs_set_watchpoint (inferior_ptid, ADDR, LEN, TYPE, 1)
+#define target_remove_watchpoint(ADDR, LEN, TYPE) \
+ procfs_set_watchpoint (inferior_ptid, ADDR, 0, 0, 0)
+
+#endif /* NEW_PROC_API */
diff --git a/contrib/gdb/gdb/config/i386/nm-i386v.h b/contrib/gdb/gdb/config/i386/nm-i386v.h
index 8e6877e..e7bfca4 100644
--- a/contrib/gdb/gdb/config/i386/nm-i386v.h
+++ b/contrib/gdb/gdb/config/i386/nm-i386v.h
@@ -1,22 +1,24 @@
/* Native support for i386.
- Copyright 1986, 1987, 1989, 1992 Free Software Foundation, Inc.
+ Copyright 1986, 1987, 1989, 1992, 1993, 1998, 2000
+ Free Software Foundation, Inc.
Changes for 80386 by Pace Willisson (pace@prep.ai.mit.edu), July 1988.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
#if 0
/* code to execute to print interesting information about the
@@ -27,10 +29,9 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
do this unless we *know* we aren't cross-debugging. FIXME.
*/
#define FLOAT_INFO { i386_float_info (); }
-#endif /*0*/
+#endif /*0 */
#define REGISTER_U_ADDR(addr, blockend, regno) \
(addr) = i386_register_u_addr ((blockend),(regno));
-extern int
-i386_register_u_addr PARAMS ((int, int));
+extern int i386_register_u_addr (int, int);
diff --git a/contrib/gdb/gdb/config/i386/nm-i386v4.h b/contrib/gdb/gdb/config/i386/nm-i386v4.h
index 8722a40..02d445e 100644
--- a/contrib/gdb/gdb/config/i386/nm-i386v4.h
+++ b/contrib/gdb/gdb/config/i386/nm-i386v4.h
@@ -1,22 +1,24 @@
/* Native support for i386 running SVR4.
- Copyright 1986, 1987, 1989, 1992, 1996 Free Software Foundation, Inc.
+ Copyright 1986, 1987, 1989, 1992, 1993, 1996
+ Free Software Foundation, Inc.
Changes for 80386 by Pace Willisson (pace@prep.ai.mit.edu), July 1988.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
#include "nm-sysv4.h"
diff --git a/contrib/gdb/gdb/config/i386/nm-i386v42mp.h b/contrib/gdb/gdb/config/i386/nm-i386v42mp.h
index 6ffd128..72e440d 100644
--- a/contrib/gdb/gdb/config/i386/nm-i386v42mp.h
+++ b/contrib/gdb/gdb/config/i386/nm-i386v42mp.h
@@ -1,22 +1,23 @@
/* Native support for i386 running SVR4.
- Copyright 1986, 1987, 1989, 1992, 1996 Free Software Foundation, Inc.
+ Copyright 1986, 1987, 1989, 1992, 1996, 1997, 1998
+ Free Software Foundation, Inc.
Changes for 80386 by Pace Willisson (pace@prep.ai.mit.edu), July 1988.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
#include "nm-sysv4.h"
-
diff --git a/contrib/gdb/gdb/config/i386/nm-linux.h b/contrib/gdb/gdb/config/i386/nm-linux.h
index ad0b8db..8ae3ece 100644
--- a/contrib/gdb/gdb/config/i386/nm-linux.h
+++ b/contrib/gdb/gdb/config/i386/nm-linux.h
@@ -1,73 +1,83 @@
-/* Native support for GNU/Linux, for GDB, the GNU debugger.
- Copyright (C) 1986, 1987, 1989, 1992, 1996, 1998
- Free Software Foundation, Inc.
+/* Native support for GNU/Linux x86.
-This file is part of GDB.
+ Copyright 1986, 1987, 1989, 1992, 1993, 1994, 1995, 1996, 1997,
+ 1998, 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This file is part of GDB.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is 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.
-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 program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
#ifndef NM_LINUX_H
#define NM_LINUX_H
-#include "i386/nm-i386v.h"
+/* GNU/Linux supports the i386 hardware debugging registers. */
+#define I386_USE_GENERIC_WATCHPOINTS
+
+#include "i386/nm-i386.h"
+#include "nm-linux.h"
-/* Return sizeof user struct to callers in less machine dependent routines */
+/* Support for the user area. */
+/* Return the size of the user struct. */
+extern int kernel_u_size (void);
#define KERNEL_U_SIZE kernel_u_size()
-extern int kernel_u_size PARAMS ((void));
-/* Tell gdb that we can attach and detach other processes */
-#define ATTACH_DETACH
+/* This is the amount to substract from u.u_ar0 to get the offset in
+ the core file of the register values. */
+#define KERNEL_U_ADDR 0
+/* Offset of the registers within the user area. */
#define U_REGS_OFFSET 0
-/* GNU/Linux supports the 386 hardware debugging registers. */
-
-#define TARGET_HAS_HARDWARE_WATCHPOINTS
-
-#define TARGET_CAN_USE_HARDWARE_WATCHPOINT(type, cnt, ot) 1
-
-/* After a watchpoint trap, the PC points to the instruction after
- the one that caused the trap. Therefore we don't need to step over it.
- But we do need to reset the status register to avoid another trap. */
-#define HAVE_CONTINUABLE_WATCHPOINT
-
-#define STOPPED_BY_WATCHPOINT(W) \
- i386_stopped_by_watchpoint (inferior_pid)
-
-/* Use these macros for watchpoint insertion/removal. */
-
-#define target_insert_watchpoint(addr, len, type) \
- i386_insert_watchpoint (inferior_pid, addr, len, type)
-
-#define target_remove_watchpoint(addr, len, type) \
- i386_remove_watchpoint (inferior_pid, addr, len)
-
-/* We define this if link.h is available, because with ELF we use SVR4 style
- shared libraries. */
-
-#ifdef HAVE_LINK_H
-#define SVR4_SHARED_LIBS
-#include "solib.h" /* Support for shared libraries. */
-#endif
-
-extern CORE_ADDR
-i386_stopped_by_watchpoint PARAMS ((int));
-extern int
-i386_insert_watchpoint PARAMS ((int pid, CORE_ADDR addr, int len, int rw));
-extern int
-i386_remove_watchpoint PARAMS ((int pid, CORE_ADDR addr, int len));
-
-#endif /* #ifndef NM_LINUX_H */
+extern CORE_ADDR register_u_addr (CORE_ADDR blockend, int regnum);
+#define REGISTER_U_ADDR(addr, blockend, regnum) \
+ (addr) = register_u_addr (blockend, regnum)
+
+/* Provide access to the i386 hardware debugging registers. */
+
+extern void i386_linux_dr_set_control (unsigned long control);
+#define I386_DR_LOW_SET_CONTROL(control) \
+ i386_linux_dr_set_control (control)
+
+extern void i386_linux_dr_set_addr (int regnum, CORE_ADDR addr);
+#define I386_DR_LOW_SET_ADDR(regnum, addr) \
+ i386_linux_dr_set_addr (regnum, addr)
+
+extern void i386_linux_dr_reset_addr (int regnum);
+#define I386_DR_LOW_RESET_ADDR(regnum) \
+ i386_linux_dr_reset_addr (regnum)
+
+extern unsigned long i386_linux_dr_get_status (void);
+#define I386_DR_LOW_GET_STATUS() \
+ i386_linux_dr_get_status ()
+
+
+/* Override copies of {fetch,store}_inferior_registers in `infptrace.c'. */
+#define FETCH_INFERIOR_REGISTERS
+
+/* Nevertheless, define CANNOT_{FETCH,STORE}_REGISTER, because we
+ might fall back on the code `infptrace.c' (well a copy of that code
+ in `i386-linux-nat.c' for now) and we can access only the
+ general-purpose registers in that way. */
+extern int cannot_fetch_register (int regno);
+extern int cannot_store_register (int regno);
+#define CANNOT_FETCH_REGISTER(regno) cannot_fetch_register (regno)
+#define CANNOT_STORE_REGISTER(regno) cannot_store_register (regno)
+
+/* Override child_resume in `infptrace.c'. */
+#define CHILD_RESUME
+
+#endif /* nm-linux.h */
diff --git a/contrib/gdb/gdb/config/i386/nm-m3.h b/contrib/gdb/gdb/config/i386/nm-m3.h
index 5127091..00128cf 100644
--- a/contrib/gdb/gdb/config/i386/nm-m3.h
+++ b/contrib/gdb/gdb/config/i386/nm-m3.h
@@ -1,21 +1,22 @@
/* Native-dependent definitions for Intel 386 running Mach 3.
Copyright 1994 Free Software Foundation, Inc.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
/* Include the generic Mach 3 definitions. */
diff --git a/contrib/gdb/gdb/config/i386/nm-nbsd.h b/contrib/gdb/gdb/config/i386/nm-nbsd.h
index b59fec6..f926f9b 100644
--- a/contrib/gdb/gdb/config/i386/nm-nbsd.h
+++ b/contrib/gdb/gdb/config/i386/nm-nbsd.h
@@ -1,34 +1,33 @@
/* Native-dependent definitions for Intel 386 running NetBSD, for GDB.
- Copyright 1986, 1987, 1989, 1992, 1994 Free Software Foundation, Inc.
+ Copyright 1986, 1987, 1989, 1992, 1994, 1996, 2000
+ Free Software Foundation, Inc.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
#ifndef NM_NBSD_H
#define NM_NBSD_H
/* Get generic NetBSD native definitions. */
-#include "nm-nbsd.h"
-
-/* #define FLOAT_INFO { i386_float_info(); } */
+#include "config/nm-nbsd.h"
#define REGISTER_U_ADDR(addr, blockend, regno) \
(addr) = i386_register_u_addr ((blockend),(regno));
-extern int
-i386_register_u_addr PARAMS ((int, int));
+extern int i386_register_u_addr (int, int);
#endif /* NM_NBSD_H */
diff --git a/contrib/gdb/gdb/config/i386/nm-nbsdelf.h b/contrib/gdb/gdb/config/i386/nm-nbsdelf.h
new file mode 100644
index 0000000..1aee1c7
--- /dev/null
+++ b/contrib/gdb/gdb/config/i386/nm-nbsdelf.h
@@ -0,0 +1,28 @@
+/* Native-dependent definitions for Intel 386 running NetBSD, for GDB.
+ Copyright 1986, 1987, 1989, 1992, 1994, 2000
+ Free Software Foundation, Inc.
+
+ This file is part of GDB.
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
+
+#ifndef NM_NBSDELF_H
+#define NM_NBSDELF_H
+
+#define SVR4_SHARED_LIBS
+#include "i386/nm-nbsd.h"
+
+#endif /* NM_NBSDELF_H */
diff --git a/contrib/gdb/gdb/config/i386/nm-obsd.h b/contrib/gdb/gdb/config/i386/nm-obsd.h
new file mode 100644
index 0000000..6113e14
--- /dev/null
+++ b/contrib/gdb/gdb/config/i386/nm-obsd.h
@@ -0,0 +1,110 @@
+/* Native-dependent definitions for OpenBSD/i386.
+ Copyright 2001 Free Software Foundation, Inc.
+
+ This file is part of GDB.
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
+
+#ifndef NM_OBSD_H
+#define NM_OBSD_H
+
+/* Type of the third argument to the `ptrace' system call. */
+#define PTRACE_ARG3_TYPE caddr_t
+
+/* Override copies of {fetch,store}_inferior_registers in `infptrace.c'. */
+#define FETCH_INFERIOR_REGISTERS
+
+/* We can attach and detach. */
+#define ATTACH_DETACH
+
+
+/* Support for the user struct. */
+
+/* Return the size of the user struct. */
+
+#define KERNEL_U_SIZE kernel_u_size ()
+extern int kernel_u_size (void);
+
+/* This is the amount to subtract from u.u_ar0
+ to get the offset in the core file of the register values. */
+
+#include <machine/vmparam.h>
+#define KERNEL_U_ADDR USRSTACK
+
+#define REGISTER_U_ADDR(addr, blockend, regno) \
+ (addr) = register_u_addr ((blockend), (regno))
+extern CORE_ADDR register_u_addr (CORE_ADDR blockend, int regno);
+
+
+/* Shared library support. */
+
+#include "solib.h" /* Support for shared libraries. */
+
+/* Make structure definitions match up with those expected in `solib.c'. */
+
+#define link_object sod
+#define lo_name sod_name
+#define lo_library sod_library
+#define lo_unused sod_reserved
+#define lo_major sod_major
+#define lo_minor sod_minor
+#define lo_next sod_next
+
+#define link_map so_map
+#define lm_addr som_addr
+#define lm_name som_path
+#define lm_next som_next
+#define lm_lop som_sod
+#define lm_lob som_sodbase
+#define lm_rwt som_write
+#define lm_ld som_dynamic
+#define lm_lpd som_spd
+
+#define link_dynamic_2 section_dispatch_table
+#define ld_loaded sdt_loaded
+#define ld_need sdt_sods
+#define ld_rules sdt_filler1
+#define ld_got sdt_got
+#define ld_plt sdt_plt
+#define ld_rel sdt_rel
+#define ld_hash sdt_hash
+#define ld_stab sdt_nzlist
+#define ld_stab_hash sdt_filler2
+#define ld_buckets sdt_buckets
+#define ld_symbols sdt_strings
+#define ld_symb_size sdt_str_sz
+#define ld_text sdt_text_sz
+#define ld_plt_sz sdt_plt_sz
+
+#define rtc_symb rt_symbol
+#define rtc_sp rt_sp
+#define rtc_next rt_next
+
+#define ld_debug so_debug
+#define ldd_version dd_version
+#define ldd_in_debugger dd_in_debugger
+#define ldd_sym_loaded dd_sym_loaded
+#define ldd_bp_addr dd_bpt_addr
+#define ldd_bp_inst dd_bpt_shadow
+#define ldd_cp dd_cc
+
+#define link_dynamic _dynamic
+#define ld_version d_version
+#define ldd d_debug
+#define ld_un d_un
+#define ld_2 d_sdt
+
+#endif /* nm-obsd.h */
diff --git a/contrib/gdb/gdb/config/i386/nm-ptx4.h b/contrib/gdb/gdb/config/i386/nm-ptx4.h
index 5e6cd56..32b76d2 100644
--- a/contrib/gdb/gdb/config/i386/nm-ptx4.h
+++ b/contrib/gdb/gdb/config/i386/nm-ptx4.h
@@ -1,22 +1,26 @@
/* Definitions to make GDB run on a Sequent Symmetry under ptx
with Weitek 1167 and i387 support.
- Copyright 1986, 1987, 1989, 1992 Free Software Foundation, Inc.
+ Copyright 1986, 1987, 1989, 1992, 1994, 1996, 2000
+ Free Software Foundation, Inc.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
+
+#include "regcache.h"
#include "nm-sysv4.h"
@@ -38,7 +42,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define CHILD_WAIT
struct target_waitstatus;
-extern int child_wait PARAMS ((int, struct target_waitstatus *));
+extern ptid_t child_wait (ptid_t, struct target_waitstatus *);
/*
* ptx does attach as of ptx version 2.1. Prior to that, the interface
@@ -49,7 +53,7 @@ extern int child_wait PARAMS ((int, struct target_waitstatus *));
* enable attach/detach. If you turn it on anyway, it will mostly
* work, but has a number of bugs. -fubar, 2/94.
*/
-/*#define ATTACH_DETACH 1*/
+/*#define ATTACH_DETACH 1 */
#undef ATTACH_DETACH
#define PTRACE_ATTACH XPT_DEBUG
#define PTRACE_DETACH XPT_UNDEBUG
diff --git a/contrib/gdb/gdb/config/i386/nm-symmetry.h b/contrib/gdb/gdb/config/i386/nm-symmetry.h
index 80cf097..a589a3d 100644
--- a/contrib/gdb/gdb/config/i386/nm-symmetry.h
+++ b/contrib/gdb/gdb/config/i386/nm-symmetry.h
@@ -1,22 +1,26 @@
/* Definitions to make GDB run on a Sequent Symmetry under dynix 3.0,
with Weitek 1167 and i387 support.
- Copyright 1986, 1987, 1989, 1992 Free Software Foundation, Inc.
+ Copyright 1986, 1987, 1989, 1992, 1994, 1996, 1998, 2000
+ Free Software Foundation, Inc.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
+
+#include "regcache.h"
/* Override copies of {fetch,store}_inferior_registers in infptrace.c. */
@@ -28,7 +32,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#ifdef _SEQUENT_
#define CHILD_WAIT
-extern int child_wait PARAMS ((int, struct target_waitstatus *));
+extern ptid_t child_wait (ptid_t, struct target_waitstatus *);
#endif
/* This is the amount to subtract from u.u_ar0
@@ -40,7 +44,7 @@ extern int child_wait PARAMS ((int, struct target_waitstatus *));
#include <sys/mc_vmparam.h>
/* VA_UAREA is defined in <sys/mc_vmparam.h>, and is dependant upon
sizeof(struct user) */
-#define KERNEL_U_ADDR (VA_UAREA) /* ptx */
+#define KERNEL_U_ADDR (VA_UAREA) /* ptx */
#else
#define KERNEL_U_ADDR (0x80000000 - (UPAGES * NBPG)) /* dynix */
#endif
diff --git a/contrib/gdb/gdb/config/i386/nm-x86-64.h b/contrib/gdb/gdb/config/i386/nm-x86-64.h
new file mode 100644
index 0000000..30e3731
--- /dev/null
+++ b/contrib/gdb/gdb/config/i386/nm-x86-64.h
@@ -0,0 +1,90 @@
+/* Native support for GNU/Linux x86-64.
+
+ Copyright 2001, 2002 Free Software Foundation, Inc. Contributed by
+ Jiri Smid, SuSE Labs.
+
+ This file is part of GDB.
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
+
+#ifndef NM_X86_64_H
+#define NM_X86_64_H
+
+#include "nm-linux.h"
+
+#define I386_USE_GENERIC_WATCHPOINTS
+#include "i386/nm-i386.h"
+
+/* Support for 8-byte wide hw watchpoints. */
+#define TARGET_HAS_DR_LEN_8 1
+
+/* Provide access to the i386 hardware debugging registers. */
+
+extern void x86_64_linux_dr_set_control (unsigned long control);
+#define I386_DR_LOW_SET_CONTROL(control) \
+ x86_64_linux_dr_set_control (control)
+
+extern void x86_64_linux_dr_set_addr (int regnum, CORE_ADDR addr);
+#define I386_DR_LOW_SET_ADDR(regnum, addr) \
+ x86_64_linux_dr_set_addr (regnum, addr)
+
+extern void x86_64_linux_dr_reset_addr (int regnum);
+#define I386_DR_LOW_RESET_ADDR(regnum) \
+ x86_64_linux_dr_reset_addr (regnum)
+
+extern unsigned long x86_64_linux_dr_get_status (void);
+#define I386_DR_LOW_GET_STATUS() \
+ x86_64_linux_dr_get_status ()
+
+
+#define REGISTER_U_ADDR(addr, blockend, regno) \
+ (addr) = x86_64_register_u_addr ((blockend),(regno));
+CORE_ADDR x86_64_register_u_addr (CORE_ADDR, int);
+
+/* Return the size of the user struct. */
+#define KERNEL_U_SIZE kernel_u_size()
+extern int kernel_u_size (void);
+
+/* Offset of the registers within the user area. */
+#define U_REGS_OFFSET 0
+
+/* This is the amount to subtract from u.u_ar0
+ to get the offset in the core file of the register values. */
+#define KERNEL_U_ADDR 0x0
+
+#define PTRACE_ARG3_TYPE void*
+#define PTRACE_XFER_TYPE unsigned long
+
+
+/* We define this if link.h is available, because with ELF we use SVR4 style
+ shared libraries. */
+
+#ifdef HAVE_LINK_H
+#define SVR4_SHARED_LIBS
+#include "solib.h" /* Support for shared libraries. */
+#endif
+
+/* Override copies of {fetch,store}_inferior_registers in `infptrace.c'. */
+#define FETCH_INFERIOR_REGISTERS
+
+#undef PREPARE_TO_PROCEED
+
+#include <signal.h>
+
+extern void lin_thread_get_thread_signals (sigset_t * mask);
+#define GET_THREAD_SIGNALS(mask) lin_thread_get_thread_signals (mask)
+
+#endif /* NM_X86_64.h */
diff --git a/contrib/gdb/gdb/config/i386/obsd.mh b/contrib/gdb/gdb/config/i386/obsd.mh
new file mode 100644
index 0000000..2bfd732
--- /dev/null
+++ b/contrib/gdb/gdb/config/i386/obsd.mh
@@ -0,0 +1,7 @@
+# Host: Intel 386 running OpenBSD
+
+XM_FILE= xm-i386.h
+
+NAT_FILE= nm-obsd.h
+# NOTE: Do not spread NATDEPFILES over several lines - it hurts BSD make.
+NATDEPFILES= fork-child.o infptrace.o inftarg.o solib.o solib-sunos.o corelow.o core-aout.o i386-nat.o i387-nat.o i386bsd-nat.o
diff --git a/contrib/gdb/gdb/config/i386/obsd.mt b/contrib/gdb/gdb/config/i386/obsd.mt
new file mode 100644
index 0000000..5c96426
--- /dev/null
+++ b/contrib/gdb/gdb/config/i386/obsd.mt
@@ -0,0 +1,3 @@
+# Target: Intel 386 running OpenBSD
+TDEPFILES= i386-tdep.o i387-tdep.o i386bsd-tdep.o
+TM_FILE= tm-obsd.h
diff --git a/contrib/gdb/gdb/config/i386/ptx.mh b/contrib/gdb/gdb/config/i386/ptx.mh
index e623538..554b411 100644
--- a/contrib/gdb/gdb/config/i386/ptx.mh
+++ b/contrib/gdb/gdb/config/i386/ptx.mh
@@ -1,7 +1,7 @@
# Host: Sequent Symmetry running ptx 1.3, with Weitek 1167 or i387
XM_FILE= xm-ptx.h
-XDEPFILES= inftarg.o fork-child.o symm-nat.o corelow.o core-aout.o
+NATDEPFILES= inftarg.o fork-child.o symm-nat.o corelow.o core-aout.o
XM_CLIBS= -lPW -lseq
NAT_FILE= nm-symmetry.h
diff --git a/contrib/gdb/gdb/config/i386/ptx4.mh b/contrib/gdb/gdb/config/i386/ptx4.mh
index 7b9d11b..e4aa55e 100644
--- a/contrib/gdb/gdb/config/i386/ptx4.mh
+++ b/contrib/gdb/gdb/config/i386/ptx4.mh
@@ -1,7 +1,8 @@
# Host: Sequent Symmetry running ptx 1.3, with Weitek 1167 or i387
XM_FILE= xm-ptx4.h
-XDEPFILES= inftarg.o fork-child.o symm-nat.o corelow.o core-aout.o solib.o core-regset.o
+NATDEPFILES= inftarg.o fork-child.o symm-nat.o corelow.o core-aout.o \
+ core-regset.o solib.o solib-svr4.o solib-legacy.o
XM_CLIBS= -lseq
NAT_FILE= nm-ptx4.h
diff --git a/contrib/gdb/gdb/config/i386/symmetry.mh b/contrib/gdb/gdb/config/i386/symmetry.mh
index 69c05bc..486a2fb 100644
--- a/contrib/gdb/gdb/config/i386/symmetry.mh
+++ b/contrib/gdb/gdb/config/i386/symmetry.mh
@@ -1,5 +1,4 @@
# Host: Sequent Symmetry running Dynix 3.0, with Weitek 1167 or i387.
-XDEPFILES=
XM_FILE= xm-symmetry.h
NAT_FILE= nm-symmetry.h
NATDEPFILES= inftarg.o fork-child.o corelow.o core-aout.o symm-nat.o
diff --git a/contrib/gdb/gdb/config/i386/tm-cygwin.h b/contrib/gdb/gdb/config/i386/tm-cygwin.h
index b1ad894..1d49133 100644
--- a/contrib/gdb/gdb/config/i386/tm-cygwin.h
+++ b/contrib/gdb/gdb/config/i386/tm-cygwin.h
@@ -1,5 +1,6 @@
/* Macro definitions for i386 running under the win32 API Unix.
- Copyright 1995, 1996 Free Software Foundation, Inc.
+ Copyright 1995, 1996, 1997, 1998, 1999, 2000
+ Free Software Foundation, Inc.
This file is part of GDB.
@@ -15,113 +16,34 @@
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. */
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
+/* Use SSE registers if winnt.h contains information about them. */
+#ifdef HAVE_CONTEXT_EXTENDED_REGISTERS
+#define HAVE_SSE_REGS
+#else
+#undef HAVE_SSE_REGS
+#endif /* CONTEXT_EXTENDED_REGISTERS */
+#define HAVE_I387_REGS
-#include "i386/tm-i386v.h"
-
-#undef MAX_REGISTER_RAW_SIZE
-#undef MAX_REGISTER_VIRTUAL_SIZE
-#undef NUM_REGS
-#undef REGISTER_BYTE
-#undef REGISTER_BYTES
-#undef REGISTER_CONVERTIBLE
-#undef REGISTER_CONVERT_TO_RAW
-#undef REGISTER_CONVERT_TO_VIRTUAL
-#undef REGISTER_NAMES
-#undef REGISTER_RAW_SIZE
-#undef REGISTER_VIRTUAL_SIZE
-#undef REGISTER_VIRTUAL_TYPE
-
-/* Number of machine registers */
-
-#define NUM_REGS 24
-
-/* Initializer for an array of names of registers.
- There should be NUM_REGS strings in this initializer. */
-
-/* the order of the first 8 registers must match the compiler's
- * numbering scheme (which is the same as the 386 scheme)
- * also, this table must match regmap in i386-pinsn.c.
- */
-
-#define REGISTER_NAMES { "eax", "ecx", "edx", "ebx", \
- "esp", "ebp", "esi", "edi", \
- "eip", "ps", "cs", "ss", \
- "ds", "es", "fs", "gs", \
- "st", "st(1)","st(2)","st(3)",\
- "st(4)","st(5)","st(6)","st(7)",}
-
-#define FP0_REGNUM 16
-
-/* Total amount of space needed to store our copies of the machine's
- register state, the array `registers'. */
-
-#define REGISTER_BYTES (16 * 4 + 8 * 10)
-
-/* Index within `registers' of the first byte of the space for
- register N. */
-
-#define REGISTER_BYTE(N) (((N) < 16) ? (N) * 4 : (((N) - 16) * 10) + (16 * 4))
-
-/* Number of bytes of storage in the actual machine representation
- for register N. */
-
-#define REGISTER_RAW_SIZE(N) (((N) < 16) ? 4 : 10)
-
-/* Number of bytes of storage in the program's representation
- for register N. */
-
-#define REGISTER_VIRTUAL_SIZE(N) (((N) < 16) ? 4 : 10)
-
-/* Largest value REGISTER_RAW_SIZE can have. */
-
-#define MAX_REGISTER_RAW_SIZE 10
-
-/* Largest value REGISTER_VIRTUAL_SIZE can have. */
-
-#define MAX_REGISTER_VIRTUAL_SIZE 10
-
-/* Nonzero if register N requires conversion
- from raw format to virtual format. */
-
-#define REGISTER_CONVERTIBLE(N) \
- ((N < FP0_REGNUM) ? 0 : 1)
-
-/* Convert data from raw format for register REGNUM in buffer FROM
- to virtual format with type TYPE in buffer TO. */
-extern void
-i387_to_double PARAMS ((char *, char *));
-
-
-#define REGISTER_CONVERT_TO_VIRTUAL(REGNUM,TYPE,FROM,TO) \
-{ \
- double val; \
- i387_to_double ((FROM), (char *)&val); \
- store_floating ((TO), TYPE_LENGTH (TYPE), val); \
-}
-
-extern void
-double_to_i387 PARAMS ((char *, char *));
-
-#define REGISTER_CONVERT_TO_RAW(TYPE,REGNUM,FROM,TO) \
-{ \
- double val = extract_floating ((FROM), TYPE_LENGTH (TYPE)); \
- double_to_i387((char *)&val, (TO)); \
-}
-
-/* Return the GDB type object for the "standard" data type
- of data in register N. */
-
-#define REGISTER_VIRTUAL_TYPE(N) \
- ((N < FP0_REGNUM) ? builtin_type_int : \
- builtin_type_double)
-
-#define NAMES_HAVE_UNDERSCORE
+#include "i386/tm-i386.h"
+#if 0
#define IN_SOLIB_CALL_TRAMPOLINE(pc, name) skip_trampoline_code (pc, name)
#define SKIP_TRAMPOLINE_CODE(pc) skip_trampoline_code (pc, 0)
-extern CORE_ADDR skip_trampoline_code PARAMS ((CORE_ADDR pc, char *name));
-
-extern char *cygwin_pid_to_str PARAMS ((int pid));
-#define target_pid_to_str(PID) cygwin_pid_to_str (PID)
+extern CORE_ADDR skip_trampoline_code (CORE_ADDR pc, char *name);
+#endif
+
+#define ATTACH_NO_WAIT
+#define SOLIB_ADD(filename, from_tty, targ, readsyms) child_solib_add(filename, from_tty, targ, readsyms)
+#define SOLIB_LOADED_LIBRARY_PATHNAME(pid) child_solib_loaded_library_pathname(pid)
+#define CLEAR_SOLIB child_clear_solibs
+#define ADD_SHARED_SYMBOL_FILES dll_symbol_command
+
+struct target_ops;
+char *cygwin_pid_to_str (ptid_t ptid);
+void child_solib_add (char *, int, struct target_ops *, int);
+char *child_solib_loaded_library_pathname(int);
+void child_clear_solibs (void);
+void dll_symbol_command (char *, int);
diff --git a/contrib/gdb/gdb/config/i386/tm-fbsd.h b/contrib/gdb/gdb/config/i386/tm-fbsd.h
index 9933e10..61f5de5 100644
--- a/contrib/gdb/gdb/config/i386/tm-fbsd.h
+++ b/contrib/gdb/gdb/config/i386/tm-fbsd.h
@@ -1,32 +1,89 @@
-/* Target macro definitions for i386 running FreeBSD
- Copyright (C) 1997 Free Software Foundation, Inc.
+/* Target-dependent definitions for FreeBSD/i386.
+ Copyright 1997, 1999, 2000, 2001 Free Software Foundation, Inc.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
-#include "i386/tm-i386bsd.h"
+#ifndef TM_FBSD_H
+#define TM_FBSD_H
+#define HAVE_I387_REGS
+#include "i386/tm-i386.h"
-#undef NUM_REGS
-#define NUM_REGS 14
+/* FreeBSD/ELF uses stabs-in-ELF with the DWARF register numbering
+ scheme by default, so we must redefine STAB_REG_TO_REGNUM. This
+ messes up the floating-point registers for a.out, but there is not
+ much we can do about that. */
+#undef STAB_REG_TO_REGNUM
+#define STAB_REG_TO_REGNUM(reg) i386_dwarf_reg_to_regnum ((reg))
-#undef IN_SOLIB_CALL_TRAMPOLINE
-#define IN_SOLIB_CALL_TRAMPOLINE(pc, name) STREQ (name, "_DYNAMIC")
+/* FreeBSD uses the old gcc convention for struct returns. */
+#define USE_STRUCT_CONVENTION(gcc_p, type) \
+ generic_use_struct_convention (1, type)
+
-extern i386_float_info ();
-#define FLOAT_INFO i386_float_info ()
+/* Support for longjmp. */
+
+/* Details about jmp_buf. It's supposed to be an array of integers. */
+
+#define JB_ELEMENT_SIZE 4 /* Size of elements in jmp_buf. */
+#define JB_PC 0 /* Array index of saved PC. */
+
+/* Figure out where the longjmp will land. Store the address that
+ longjmp will jump to in *ADDR, and return non-zero if successful. */
+
+#define GET_LONGJMP_TARGET(addr) get_longjmp_target (addr)
+extern int get_longjmp_target (CORE_ADDR *addr);
+
+
+/* Support for signal handlers. */
+
+#define IN_SIGTRAMP(pc, name) i386bsd_in_sigtramp (pc, name)
+extern int i386bsd_in_sigtramp (CORE_ADDR pc, char *name);
+
+/* These defines allow the recognition of sigtramps as a function name
+ <sigtramp>.
+
+ FIXME: kettenis/2001-07-13: These should be added to the target
+ vector and turned into functions when we go "multi-arch". */
+
+#define SIGTRAMP_START(pc) i386bsd_sigtramp_start
+#define SIGTRAMP_END(pc) i386bsd_sigtramp_end
+extern CORE_ADDR i386bsd_sigtramp_start;
+extern CORE_ADDR i386bsd_sigtramp_end;
+
+/* Override FRAME_SAVED_PC to enable the recognition of signal handlers. */
+
+#undef FRAME_SAVED_PC
+#define FRAME_SAVED_PC(frame) i386bsd_frame_saved_pc (frame)
+extern CORE_ADDR i386bsd_frame_saved_pc (struct frame_info *frame);
+
+
+/* Shared library support. */
+
+#ifndef SVR4_SHARED_LIBS
+
+/* Return non-zero if we are in a shared library trampoline code stub. */
+
+#define IN_SOLIB_CALL_TRAMPOLINE(pc, name) \
+ (name && !strcmp(name, "_DYNAMIC"))
+
+#endif /* !SVR4_SHARED_LIBS */
+
+#endif /* TM_FBSD_H */
diff --git a/contrib/gdb/gdb/config/i386/tm-go32.h b/contrib/gdb/gdb/config/i386/tm-go32.h
new file mode 100644
index 0000000..b660827
--- /dev/null
+++ b/contrib/gdb/gdb/config/i386/tm-go32.h
@@ -0,0 +1,68 @@
+/* Target-dependent definitions for Intel x86 running DJGPP.
+ Copyright 1995, 1996, 1997, 1999, 2000 Free Software Foundation, Inc.
+
+ This file is part of GDB.
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
+
+#ifndef TM_GO32_H
+#define TM_GO32_H
+
+#undef HAVE_SSE_REGS /* FIXME! go32-nat.c needs to support XMMi registers */
+#define HAVE_I387_REGS
+
+#include "i386/tm-i386.h"
+
+/* FRAME_CHAIN takes a frame's nominal address and produces the frame's
+ chain-pointer.
+ In the case of the i386, the frame's nominal address
+ is the address of a 4-byte word containing the calling frame's address.
+ DJGPP doesn't have any special frames for signal handlers, they are
+ just normal C functions. */
+#undef FRAME_CHAIN
+#define FRAME_CHAIN(thisframe) \
+ (!inside_entry_file ((thisframe)->pc) ? \
+ read_memory_integer ((thisframe)->frame, 4) :\
+ 0)
+
+/* A macro that tells us whether the function invocation represented
+ by FI does not have a frame on the stack associated with it. If it
+ does not, FRAMELESS is set to 1, else 0. */
+#undef FRAMELESS_FUNCTION_INVOCATION
+#define FRAMELESS_FUNCTION_INVOCATION(FI) \
+ (frameless_look_for_prologue(FI))
+
+extern CORE_ADDR i386go32_frame_saved_pc (struct frame_info *frame);
+#undef FRAME_SAVED_PC
+#define FRAME_SAVED_PC(FRAME) (i386go32_frame_saved_pc ((FRAME)))
+
+/* Support for longjmp. */
+
+/* Details about jmp_buf. It's supposed to be an array of integers. */
+
+#define JB_ELEMENT_SIZE 4 /* Size of elements in jmp_buf. */
+#define JB_PC 8 /* Array index of saved PC inside jmp_buf. */
+
+/* Figure out where the longjmp will land. Slurp the args out of the
+ stack. We expect the first arg to be a pointer to the jmp_buf
+ structure from which we extract the pc (JB_PC) that we will land
+ at. The pc is copied into ADDR. This routine returns true on
+ success. */
+
+#define GET_LONGJMP_TARGET(addr) get_longjmp_target (addr)
+extern int get_longjmp_target (CORE_ADDR *addr);
+
+#endif /* TM_GO32_H */
diff --git a/contrib/gdb/gdb/config/i386/tm-i386.h b/contrib/gdb/gdb/config/i386/tm-i386.h
index e2039e5..f9326fe 100644
--- a/contrib/gdb/gdb/config/i386/tm-i386.h
+++ b/contrib/gdb/gdb/config/i386/tm-i386.h
@@ -1,37 +1,49 @@
/* Macro definitions for GDB on an Intel i[345]86.
- Copyright (C) 1995, 1996 Free Software Foundation, Inc.
+ Copyright 1995, 1996, 1998, 1999, 2000, 2001
+ Free Software Foundation, Inc.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
#ifndef TM_I386_H
#define TM_I386_H 1
-#ifdef __STDC__ /* Forward decl's for prototypes */
+#define GDB_MULTI_ARCH GDB_MULTI_ARCH_PARTIAL
+
+#include "regcache.h"
+
+/* Forward declarations for prototypes. */
struct frame_info;
struct frame_saved_regs;
+struct value;
struct type;
-#endif
-#define TARGET_BYTE_ORDER LITTLE_ENDIAN
+/* The format used for `long double' on almost all i386 targets is the
+ i387 extended floating-point format. In fact, of all targets in the
+ GCC 2.95 tree, only OSF/1 does it different, and insists on having
+ a `long double' that's not `long' at all. */
-/* Used for example in valprint.c:print_floating() to enable checking
- for NaN's */
+#define TARGET_LONG_DOUBLE_FORMAT &floatformat_i387_ext
-#define IEEE_FLOAT
+/* Although the i386 extended floating-point has only 80 significant
+ bits, a `long double' actually takes up 96, probably to enforce
+ alignment. */
+
+#define TARGET_LONG_DOUBLE_BIT 96
/* 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
@@ -47,15 +59,14 @@ struct type;
/* Advance PC across any function entry prologue instructions to reach some
"real" code. */
-#define SKIP_PROLOGUE(frompc) {(frompc) = i386_skip_prologue((frompc));}
+#define SKIP_PROLOGUE(frompc) (i386_skip_prologue (frompc))
-extern int i386_skip_prologue PARAMS ((int));
+extern int i386_skip_prologue (int);
-/* Immediately after a function call, return the saved pc. Can't always go
- through the frames for this because on some machines the new frame is not
- set up until the new function executes some instructions. */
+/* Immediately after a function call, return the saved pc. */
-#define SAVED_PC_AFTER_CALL(frame) (read_memory_integer (read_register (SP_REGNUM), 4))
+#define SAVED_PC_AFTER_CALL(frame) i386_saved_pc_after_call (frame)
+extern CORE_ADDR i386_saved_pc_after_call (struct frame_info *frame);
/* Stack grows downward. */
@@ -76,24 +87,38 @@ extern int i386_skip_prologue PARAMS ((int));
#define REGISTER_SIZE 4
-/* Number of machine registers */
-
-#define NUM_FREGS 0 /*8*/ /* Number of FP regs */
-#define NUM_REGS (16 + NUM_FREGS) /* Basic i*86 regs + FP regs */
+/* This register file is parameterized by two macros:
+ HAVE_I387_REGS --- register file should include i387 registers
+ HAVE_SSE_REGS --- register file should include SSE registers
+ If HAVE_SSE_REGS is #defined, then HAVE_I387_REGS must also be #defined.
+
+ However, GDB code should not test those macros with #ifdef, since
+ that makes code which is annoying to multi-arch. Instead, GDB code
+ should check the values of NUM_GREGS, NUM_FREGS, and NUM_SSE_REGS,
+ which will eventually get mapped onto architecture vector entries.
+
+ It's okay to use the macros in tm-*.h files, though, since those
+ files will get completely replaced when we multi-arch anyway. */
+
+/* Number of general registers, present on every 32-bit x86 variant. */
+#define NUM_GREGS (16)
+
+/* Number of floating-point unit registers. */
+#ifdef HAVE_I387_REGS
+#define NUM_FREGS (16)
+#else
+#define NUM_FREGS (0)
+#endif
-/* Initializer for an array of names of registers. There should be at least
- NUM_REGS strings in this initializer. Any excess ones are simply ignored.
- The order of the first 8 registers must match the compiler's numbering
- scheme (which is the same as the 386 scheme) and also regmap in the various
- *-nat.c files. */
+/* Number of SSE registers. */
+#ifdef HAVE_SSE_REGS
+#define NUM_SSE_REGS (9)
+#else
+#define NUM_SSE_REGS (0)
+#endif
-#define REGISTER_NAMES { "eax", "ecx", "edx", "ebx", \
- "esp", "ebp", "esi", "edi", \
- "eip", "eflags", "cs", "ss", \
- "ds", "es", "fs", "gs", \
- "st0", "st1", "st2", "st3", \
- "st4", "st5", "st6", "st7", \
- }
+/* Largest number of registers we could have in any configuration. */
+#define MAX_NUM_REGS (16 + 16 + 9)
/* Register numbers of various important registers.
Note that some of these values are "real" register numbers,
@@ -102,128 +127,178 @@ extern int i386_skip_prologue PARAMS ((int));
to be actual register numbers as far as the user is concerned
but do serve to get the desired values when passed to read_register. */
-#define FP_REGNUM 5 /* (ebp) Contains address of executing stack frame */
-#define SP_REGNUM 4 /* (usp) Contains address of top of stack */
-#define PC_REGNUM 8 /* (eip) Contains program counter */
-#define PS_REGNUM 9 /* (ps) Contains processor status */
+#define FP_REGNUM 5 /* (ebp) Contains address of executing stack
+ frame */
+#define SP_REGNUM 4 /* (usp) Contains address of top of stack */
+#define PC_REGNUM 8 /* (eip) Contains program counter */
+#define PS_REGNUM 9 /* (ps) Contains processor status */
+
+/* First FPU data register. */
+#ifdef HAVE_I387_REGS
+#define FP0_REGNUM 16
+#else
+#define FP0_REGNUM 0
+#endif
+
+/* Return the name of register REG. */
+
+#define REGISTER_NAME(reg) i386_register_name ((reg))
+extern char *i386_register_name (int reg);
+
+/* Use the "default" register numbering scheme for stabs and COFF. */
+
+#define STAB_REG_TO_REGNUM(reg) i386_stab_reg_to_regnum ((reg))
+#define SDB_REG_TO_REGNUM(reg) i386_stab_reg_to_regnum ((reg))
+extern int i386_stab_reg_to_regnum (int reg);
+
+/* Use the DWARF register numbering scheme for DWARF and DWARF 2. */
+
+#define DWARF_REG_TO_REGNUM(reg) i386_dwarf_reg_to_regnum ((reg))
+#define DWARF2_REG_TO_REGNUM(reg) i386_dwarf_reg_to_regnum ((reg))
+extern int i386_dwarf_reg_to_regnum (int reg);
+
+/* We don't define ECOFF_REG_TO_REGNUM, since ECOFF doesn't seem to be
+ in use on any of the supported i386 targets. */
+
+
+/* Sizes of individual register sets. These cover the entire register
+ file, so summing up the sizes of those portions actually present
+ yields REGISTER_BYTES. */
+#define SIZEOF_GREGS (NUM_GREGS * 4)
+#define SIZEOF_FPU_REGS (8 * 10)
+#define SIZEOF_FPU_CTRL_REGS (8 * 4)
+#define SIZEOF_SSE_REGS (8 * 16 + 4)
-#define FP0_REGNUM 16 /* (st0) 387 register */
-#define FPC_REGNUM 25 /* 80387 control register */
/* Total amount of space needed to store our copies of the machine's register
state, the array `registers'. */
+#ifdef HAVE_SSE_REGS
+#define REGISTER_BYTES \
+ (SIZEOF_GREGS + SIZEOF_FPU_REGS + SIZEOF_FPU_CTRL_REGS + SIZEOF_SSE_REGS)
+#else
+#ifdef HAVE_I387_REGS
+#define REGISTER_BYTES (SIZEOF_GREGS + SIZEOF_FPU_REGS + SIZEOF_FPU_CTRL_REGS)
+#else
+#define REGISTER_BYTES (SIZEOF_GREGS)
+#endif
+#endif
-#define REGISTER_BYTES ((NUM_REGS - NUM_FREGS)*4 + NUM_FREGS*10)
+/* Return the offset into the register array of the start of register
+ number REG. */
+#define REGISTER_BYTE(reg) i386_register_byte ((reg))
+extern int i386_register_byte (int reg);
-/* Index within `registers' of the first byte of the space for register N. */
+/* Return the number of bytes of storage in GDB's register array
+ occupied by register REG. */
+#define REGISTER_RAW_SIZE(reg) i386_register_raw_size ((reg))
+extern int i386_register_raw_size (int reg);
-#define REGISTER_BYTE(N) \
- (((N) < FP0_REGNUM) ? ((N) * 4) : ((((N) - FP0_REGNUM) * 10) + 64))
-
-/* Number of bytes of storage in the actual machine representation for
- register N. All registers are 4 bytes, except 387 st(0) - st(7),
- which are 80 bits each. */
+/* Largest value REGISTER_RAW_SIZE can have. */
+#define MAX_REGISTER_RAW_SIZE 16
-#define REGISTER_RAW_SIZE(N) (((N) < FP0_REGNUM) ? 4 : 10)
+/* Return the size in bytes of the virtual type of register REG. */
+#define REGISTER_VIRTUAL_SIZE(reg) i386_register_virtual_size ((reg))
+extern int i386_register_virtual_size (int reg);
-/* Largest value REGISTER_RAW_SIZE can have. */
+/* Largest value REGISTER_VIRTUAL_SIZE can have. */
+#define MAX_REGISTER_VIRTUAL_SIZE 16
-#define MAX_REGISTER_RAW_SIZE 10
+/* Return the GDB type object for the "standard" data type of data in
+ register REGNUM. */
-/* Number of bytes of storage in the program's representation
- for register N. */
+#define REGISTER_VIRTUAL_TYPE(regnum) i386_register_virtual_type (regnum)
+extern struct type *i386_register_virtual_type (int regnum);
-#define REGISTER_VIRTUAL_SIZE(N) (((N) < FP0_REGNUM) ? 4 : 8)
+/* Return true iff register REGNUM's virtual format is different from
+ its raw format. */
-/* Largest value REGISTER_VIRTUAL_SIZE can have. */
+#define REGISTER_CONVERTIBLE(regnum) i386_register_convertible (regnum)
+extern int i386_register_convertible (int regnum);
+
+/* Convert data from raw format for register REGNUM in buffer FROM to
+ virtual format with type TYPE in buffer TO. */
-#define MAX_REGISTER_VIRTUAL_SIZE 8
+#define REGISTER_CONVERT_TO_VIRTUAL(regnum, type, from, to) \
+ i386_register_convert_to_virtual ((regnum), (type), (from), (to))
+extern void i386_register_convert_to_virtual (int regnum, struct type *type,
+ char *from, char *to);
-/* Return the GDB type object for the "standard" data type of data in
- register N. Perhaps si and di should go here, but potentially they
- could be used for things other than address. */
+/* Convert data from virtual format with type TYPE in buffer FROM to
+ raw format for register REGNUM in buffer TO. */
+
+#define REGISTER_CONVERT_TO_RAW(type, regnum, from, to) \
+ i386_register_convert_to_raw ((type), (regnum), (from), (to))
+extern void i386_register_convert_to_raw (struct type *type, int regnum,
+ char *from, char *to);
+
+/* Print out the i387 floating point state. */
+#ifdef HAVE_I387_REGS
+extern void i387_float_info (void);
+#define FLOAT_INFO { i387_float_info (); }
+#endif
+
-#define REGISTER_VIRTUAL_TYPE(N) \
- (((N) == PC_REGNUM || (N) == FP_REGNUM || (N) == SP_REGNUM) \
- ? lookup_pointer_type (builtin_type_void) \
- : (((N) < FP0_REGNUM) \
- ? builtin_type_int \
- : builtin_type_double))
+#define PUSH_ARGUMENTS(nargs, args, sp, struct_return, struct_addr) \
+ i386_push_arguments ((nargs), (args), (sp), (struct_return), (struct_addr))
+extern CORE_ADDR i386_push_arguments (int nargs, struct value **args,
+ CORE_ADDR sp, int struct_return,
+ CORE_ADDR struct_addr);
/* Store the address of the place in which to copy the structure the
- subroutine will return. This is called from call_function. */
+ subroutine will return. This is called from call_function. */
-#define STORE_STRUCT_RETURN(ADDR, SP) \
- { char buf[REGISTER_SIZE]; \
- (SP) -= sizeof (ADDR); \
- store_address (buf, sizeof (ADDR), ADDR); \
- write_memory ((SP), buf, sizeof (ADDR)); }
+#define STORE_STRUCT_RETURN(addr, sp) \
+ i386_store_struct_return ((addr), (sp))
+extern void i386_store_struct_return (CORE_ADDR addr, CORE_ADDR sp);
/* 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 EXTRACT_RETURN_VALUE(TYPE,REGBUF,VALBUF) \
- i386_extract_return_value ((TYPE),(REGBUF),(VALBUF))
+#define EXTRACT_RETURN_VALUE(type, regbuf, valbuf) \
+ i386_extract_return_value ((type), (regbuf), (valbuf))
+extern void i386_extract_return_value (struct type *type, char *regbuf,
+ char *valbuf);
-extern void i386_extract_return_value PARAMS ((struct type *, char [], char *));
+/* Write into the appropriate registers a function return value stored
+ in VALBUF of type TYPE, given in virtual format. */
-/* Write into appropriate registers a function return value of type TYPE, given
- in virtual format. */
+#define STORE_RETURN_VALUE(type, valbuf) \
+ i386_store_return_value ((type), (valbuf))
+extern void i386_store_return_value (struct type *type, char *valbuf);
-#define STORE_RETURN_VALUE(TYPE,VALBUF) \
- { \
- if (TYPE_CODE (TYPE) == TYPE_CODE_FLT) \
- write_register_bytes (REGISTER_BYTE (FP0_REGNUM), (VALBUF), \
- TYPE_LENGTH (TYPE)); \
- else \
- 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 (or an
- expression that can be used as one). */
+/* 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. */
-#define EXTRACT_STRUCT_VALUE_ADDRESS(REGBUF) (*(int *)(REGBUF))
+#define EXTRACT_STRUCT_VALUE_ADDRESS(regbuf) \
+ i386_extract_struct_value_address ((regbuf))
+extern CORE_ADDR i386_extract_struct_value_address (char *regbuf);
/* The following redefines make backtracing through sigtramp work.
They manufacture a fake sigtramp frame and obtain the saved pc in sigtramp
from the sigcontext structure which is pushed by the kernel on the
user stack, along with a pointer to it. */
-/* FRAME_CHAIN takes a frame's nominal address and produces the frame's
- chain-pointer.
- In the case of the i386, the frame's nominal address
- is the address of a 4-byte word containing the calling frame's address. */
-
-#define FRAME_CHAIN(thisframe) \
- ((thisframe)->signal_handler_caller \
- ? (thisframe)->frame \
- : (!inside_entry_file ((thisframe)->pc) \
- ? read_memory_integer ((thisframe)->frame, 4) \
- : 0))
+/* Return the chain-pointer for FRAME. In the case of the i386, the
+ frame's nominal address is the address of a 4-byte word containing
+ the calling frame's address. */
-/* A macro that tells us whether the function invocation represented
- by FI does not have a frame on the stack associated with it. If it
- does not, FRAMELESS is set to 1, else 0. */
+#define FRAME_CHAIN(frame) i386_frame_chain ((frame))
+extern CORE_ADDR i386_frame_chain (struct frame_info *frame);
-#define FRAMELESS_FUNCTION_INVOCATION(FI, FRAMELESS) \
- do { \
- if ((FI)->signal_handler_caller) \
- (FRAMELESS) = 0; \
- else \
- (FRAMELESS) = frameless_look_for_prologue(FI); \
- } while (0)
+/* Determine whether the function invocation represented by FRAME does
+ not have a from on the stack associated with it. If it does not,
+ return non-zero, otherwise return zero. */
-/* Saved Pc. Get it from sigcontext if within sigtramp. */
+#define FRAMELESS_FUNCTION_INVOCATION(frame) \
+ i386_frameless_function_invocation (frame)
+extern int i386_frameless_function_invocation (struct frame_info *frame);
-#define FRAME_SAVED_PC(FRAME) \
- (((FRAME)->signal_handler_caller \
- ? sigtramp_saved_pc (FRAME) \
- : read_memory_integer ((FRAME)->frame + 4, 4)) \
- )
+/* Return the saved program counter for FRAME. */
-extern CORE_ADDR sigtramp_saved_pc PARAMS ((struct frame_info *));
+#define FRAME_SAVED_PC(frame) i386_frame_saved_pc (frame)
+extern CORE_ADDR i386_frame_saved_pc (struct frame_info *frame);
#define FRAME_ARGS_ADDRESS(fi) ((fi)->frame)
@@ -232,9 +307,9 @@ extern CORE_ADDR sigtramp_saved_pc PARAMS ((struct frame_info *));
/* Return number of args passed to a frame. Can return -1, meaning no way
to tell, which is typical now that the C compiler delays popping them. */
-#define FRAME_NUM_ARGS(numargs, fi) (numargs) = i386_frame_num_args(fi)
+#define FRAME_NUM_ARGS(fi) (i386_frame_num_args(fi))
-extern int i386_frame_num_args PARAMS ((struct frame_info *));
+extern int i386_frame_num_args (struct frame_info *);
/* Return number of bytes at start of arglist that are not really args. */
@@ -246,28 +321,31 @@ extern int i386_frame_num_args PARAMS ((struct frame_info *));
ways in the stack frame. sp is even more special:
the address we return for it IS the sp for the next frame. */
-#define FRAME_FIND_SAVED_REGS(frame_info, frame_saved_regs) \
-{ i386_frame_find_saved_regs ((frame_info), &(frame_saved_regs)); }
-
-extern void i386_frame_find_saved_regs PARAMS ((struct frame_info *,
- struct frame_saved_regs *));
+extern void i386_frame_init_saved_regs (struct frame_info *);
+#define FRAME_INIT_SAVED_REGS(FI) i386_frame_init_saved_regs (FI)
+
/* Things needed for making the inferior call functions. */
+/* "An argument's size is increased, if necessary, to make it a
+ multiple of [32 bit] words. This may require tail padding,
+ depending on the size of the argument" - from the x86 ABI. */
+#define PARM_BOUNDARY 32
+
/* Push an empty stack frame, to record the current PC, etc. */
#define PUSH_DUMMY_FRAME { i386_push_dummy_frame (); }
-extern void i386_push_dummy_frame PARAMS ((void));
+extern void i386_push_dummy_frame (void);
/* Discard from the stack the innermost frame, restoring all registers. */
#define POP_FRAME { i386_pop_frame (); }
-extern void i386_pop_frame PARAMS ((void));
-
+extern void i386_pop_frame (void);
+
/* this is
* call 11223344 (32 bit relative)
* int3
@@ -277,28 +355,22 @@ extern void i386_pop_frame PARAMS ((void));
#define CALL_DUMMY_LENGTH 8
-#define CALL_DUMMY_START_OFFSET 0 /* Start execution at beginning of dummy */
+#define CALL_DUMMY_START_OFFSET 0 /* Start execution at beginning of dummy */
#define CALL_DUMMY_BREAKPOINT_OFFSET 5
/* Insert the specified number of args and function address
into a call sequence of the above form stored at DUMMYNAME. */
-#define FIX_CALL_DUMMY(dummyname, pc, fun, nargs, args, type, gcc_p) \
-{ \
- int from, to, delta, loc; \
- loc = (int)(read_register (SP_REGNUM) - CALL_DUMMY_LENGTH); \
- from = loc + 5; \
- to = (int)(fun); \
- delta = to - from; \
- *((char *)(dummyname) + 1) = (delta & 0xff); \
- *((char *)(dummyname) + 2) = ((delta >> 8) & 0xff); \
- *((char *)(dummyname) + 3) = ((delta >> 16) & 0xff); \
- *((char *)(dummyname) + 4) = ((delta >> 24) & 0xff); \
-}
-
-extern void print_387_control_word PARAMS ((unsigned int));
-extern void print_387_status_word PARAMS ((unsigned int));
+#define FIX_CALL_DUMMY(dummyname, pc, fun, nargs, args, type, gcc_p) \
+ i386_fix_call_dummy (dummyname, pc, fun, nargs, args, type, gcc_p)
+extern void i386_fix_call_dummy (char *dummy, CORE_ADDR pc, CORE_ADDR fun,
+ int nargs, struct value **args,
+ struct type *type, int gcc_p);
+
+/* FIXME: kettenis/2000-06-12: These do not belong here. */
+extern void print_387_control_word (unsigned int);
+extern void print_387_status_word (unsigned int);
/* Offset from SP to first arg on stack at first instruction of a function */
diff --git a/contrib/gdb/gdb/config/i386/tm-i386aix.h b/contrib/gdb/gdb/config/i386/tm-i386aix.h
index b0121fa..a8f24ed 100644
--- a/contrib/gdb/gdb/config/i386/tm-i386aix.h
+++ b/contrib/gdb/gdb/config/i386/tm-i386aix.h
@@ -1,21 +1,23 @@
/* Macro defintions for IBM AIX PS/2 (i386).
- Copyright 1986, 1987, 1989, 1992, 1993 Free Software Foundation, Inc.
+ Copyright 1986, 1987, 1989, 1992, 1993, 1994, 1995, 2000
+ Free Software Foundation, Inc.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
/* Changes for IBM AIX PS/2 by Minh Tran-Le (tranle@intellicorp.com). */
@@ -26,42 +28,21 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include <sys/reg.h>
#ifndef I386
-# define I386 1
+#define I386 1
#endif
-#ifndef I386_AIX_TARGET
-# define I386_AIX_TARGET 1
-#endif
-
-/* Nonzero if register N requires conversion
- from raw format to virtual format. */
-
-#undef REGISTER_CONVERTIBLE
-#define REGISTER_CONVERTIBLE(N) \
- ((N < FP0_REGNUM) ? 0 : 1)
-/* Convert data from raw format for register REGNUM in buffer FROM
- to virtual format with type TYPE in buffer TO. */
+/* AIX/i386 has FPU support. However, the native configuration (which
+ is the only supported configuration) doesn't make the FPU control
+ registers available. Override the appropriate symbols such that
+ only the normal FPU registers are included in GDB's register array. */
-#undef REGISTER_CONVERT_TO_VIRTUAL
-#define REGISTER_CONVERT_TO_VIRTUAL(REGNUM,TYPE,FROM,TO) \
-{ \
- double val; \
- i387_to_double ((FROM), (char *)&val); \
- store_floating ((TO), TYPE_LENGTH (TYPE), val); \
-}
-extern void
-i387_to_double PARAMS ((char *, char *));
+#undef NUM_FPREGS
+#define NUM_FPREGS (8)
-/* Convert data from virtual format with type TYPE in buffer FROM
- to raw format for register REGNUM in buffer TO. */
+#undef NUM_REGS
+#define NUM_REGS (NUM_GREGS + NUM_FPREGS)
-#undef REGISTER_CONVERT_TO_RAW
-#define REGISTER_CONVERT_TO_RAW(TYPE,REGNUM,FROM,TO) \
-{ \
- double val = extract_floating ((FROM), TYPE_LENGTH (TYPE)); \
- double_to_i387((char *)&val, (TO)); \
-}
-extern void
-double_to_i387 PARAMS ((char *, char *));
+#undef REGISTER_BYTES
+#define REGISTER_BYTES (SIZEOF_GREGS + SIZEOF_FPU_REGS)
#endif /* TM_I386AIX_H */
diff --git a/contrib/gdb/gdb/config/i386/tm-i386bsd.h b/contrib/gdb/gdb/config/i386/tm-i386bsd.h
index 8b8c3a9..e2b2229 100644
--- a/contrib/gdb/gdb/config/i386/tm-i386bsd.h
+++ b/contrib/gdb/gdb/config/i386/tm-i386bsd.h
@@ -1,21 +1,23 @@
/* Macro definitions for i386 running under BSD Unix.
- Copyright 1986, 1987, 1989, 1991, 1992, 1993 Free Software Foundation, Inc.
+ Copyright 1986, 1987, 1989, 1991, 1992, 1993, 1994, 1995, 1996
+ Free Software Foundation, Inc.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
#ifndef TM_I386BSD_H
#define TM_I386BSD_H 1
@@ -40,4 +42,4 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/* Offset to saved PC in sigcontext, from <sys/signal.h>. */
#define SIGCONTEXT_PC_OFFSET 20
-#endif /* ifndef TM_I386BSD_H */
+#endif /* ifndef TM_I386BSD_H */
diff --git a/contrib/gdb/gdb/config/i386/tm-i386gnu.h b/contrib/gdb/gdb/config/i386/tm-i386gnu.h
index a6e3c08..00cb5a9 100644
--- a/contrib/gdb/gdb/config/i386/tm-i386gnu.h
+++ b/contrib/gdb/gdb/config/i386/tm-i386gnu.h
@@ -1,48 +1,56 @@
-/* Macro definitions for i386, GNU Hurd
- Copyright (C) 1992 Free Software Foundation, Inc.
+/* Macro definitions for i386 running the GNU Hurd.
+ Copyright 1992, 1999, 2000 Free Software Foundation, Inc.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
-/* Include common definitions for gnu systems */
+#ifndef TM_I386GNU_H
+#define TM_I386GNU_H 1
+
+/* Include common definitions for GNU systems.
+ FIXME: This does not belong here since this is supposed to contain
+ only native-dependent information. */
#include "nm-gnu.h"
/* Thread flavors used in re-setting the T bit.
- * @@ this is also bad for cross debugging.
- */
-#define THREAD_STATE_FLAVOR i386_THREAD_STATE
+ FIXME: This is native-dependent. */
+#define THREAD_STATE_FLAVOR i386_REGS_SEGS_STATE
#define THREAD_STATE_SIZE i386_THREAD_STATE_COUNT
#define THREAD_STATE_SET_TRACED(state) \
((struct i386_thread_state *)state)->efl |= 0x100
#define THREAD_STATE_CLEAR_TRACED(state) \
((((struct i386_thread_state *)state)->efl &= ~0x100), 1)
-/* we can do it */
+/* We can attach and detach.
+ FIXME: This is probably native-dependent too. */
#define ATTACH_DETACH 1
-/* Sigh. There should be a file for i386 but no sysv stuff in it */
-#include "i386/tm-i386v.h"
+#define HAVE_I387_REGS
+#include "i386/tm-i386.h"
+
+/* We use stabs-in-ELF with the DWARF register numbering scheme. */
+
+#undef STAB_REG_TO_REGNUM
+#define STAB_REG_TO_REGNUM(reg) i386_dwarf_reg_to_regnum ((reg))
+
+/* Offset to saved PC in sigcontext. */
+#define SIGCONTEXT_PC_OFFSET 68
-/* I want to test this float info code. See comment in tm-i386v.h */
-#undef FLOAT_INFO
-#define FLOAT_INFO { i386_mach3_float_info (); }
+/* We need this file for the SOLIB_TRAMPOLINE stuff. */
+#include "tm-sysv4.h"
-/* Address of end of stack space.
- * for MACH, see <machine/vmparam.h>
- * @@@ I don't know what is in the 5 ints...
- */
-#undef STACK_END_ADDR
-#define STACK_END_ADDR (0xc0000000-sizeof(int [5]))
+#endif /* TM_I386GNU_H */
diff --git a/contrib/gdb/gdb/config/i386/tm-i386lynx.h b/contrib/gdb/gdb/config/i386/tm-i386lynx.h
index 9e732b3..842f9a7 100644
--- a/contrib/gdb/gdb/config/i386/tm-i386lynx.h
+++ b/contrib/gdb/gdb/config/i386/tm-i386lynx.h
@@ -1,21 +1,22 @@
/* Macro definitions for Intel 386 running under LynxOS.
- Copyright 1993 Free Software Foundation, Inc.
+ Copyright 1993, 1995 Free Software Foundation, Inc.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
#ifndef TM_I386LYNX_H
#define TM_I386LYNX_H
diff --git a/contrib/gdb/gdb/config/i386/tm-i386m3.h b/contrib/gdb/gdb/config/i386/tm-i386m3.h
index 2f97505..edc301d 100644
--- a/contrib/gdb/gdb/config/i386/tm-i386m3.h
+++ b/contrib/gdb/gdb/config/i386/tm-i386m3.h
@@ -1,21 +1,22 @@
/* Macro definitions for i386, Mach 3.0
- Copyright (C) 1992 Free Software Foundation, Inc.
+ Copyright 1992, 1993, 1995, 1999 Free Software Foundation, Inc.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
/* Include common definitions for Mach3 systems */
#include "nm-m3.h"
@@ -40,11 +41,6 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/* we can do it */
#define ATTACH_DETACH 1
-/* Define this if the C compiler puts an underscore at the front
- of external names before giving them to the linker. */
-
-#define NAMES_HAVE_UNDERSCORE
-
/* Sigh. There should be a file for i386 but no sysv stuff in it */
#include "i386/tm-i386.h"
diff --git a/contrib/gdb/gdb/config/i386/tm-i386mk.h b/contrib/gdb/gdb/config/i386/tm-i386mk.h
index 3625efb..e46ca55 100644
--- a/contrib/gdb/gdb/config/i386/tm-i386mk.h
+++ b/contrib/gdb/gdb/config/i386/tm-i386mk.h
@@ -1,21 +1,22 @@
/* Macro definitions for i386, Mach 3.0, OSF 1/MK
- Copyright (C) 1992 Free Software Foundation, Inc.
+ Copyright 1992, 1993, 2000 Free Software Foundation, Inc.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
/* Until OSF switches to a newer Mach kernel that has
* a different get_emul_vector() interface.
@@ -23,3 +24,15 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define MK67 1
#include "i386/tm-i386m3.h"
+
+/* FIMXE: kettenis/2000-03-26: On OSF 1, `long double' is equivalent
+ to `double'. However, I'm not sure what is the consequence of:
+
+ #define TARGET_LONG_DOUBLE_FORMAT TARGET_DOUBLE_FORMAT
+ #define TARGET_LONG_DOUBLE_BIT TARGET_DOUBLE_BIT
+
+ So I'll go with the current status quo instead. It looks like this
+ target won't compile anyway. Perhaps it should be obsoleted? */
+
+#undef TARGET_LONG_DOUBLE_FORMAT
+#undef TARGET_LONG_DOUBLE_BIT
diff --git a/contrib/gdb/gdb/config/i386/tm-i386nw.h b/contrib/gdb/gdb/config/i386/tm-i386nw.h
index e5cdade..9ede2c0 100644
--- a/contrib/gdb/gdb/config/i386/tm-i386nw.h
+++ b/contrib/gdb/gdb/config/i386/tm-i386nw.h
@@ -1,21 +1,23 @@
/* Macro definitions for i386 running NetWare.
- Copyright 1993, 1994 Free Software Foundation, Inc.
+ Copyright 1993, 1994, 1995, 1998, 1999, 2000
+ Free Software Foundation, Inc.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
#ifndef TM_I386NW_H
#define TM_I386NW_H 1
@@ -24,7 +26,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/* Stop backtracing when we wander into main. */
-#define FRAME_CHAIN_VALID(fp,fi) alternate_frame_chain_valid (fp, fi)
+#define FRAME_CHAIN_VALID(fp,fi) func_frame_chain_valid (fp, fi)
/* Offsets (in target ints) into jmp_buf. Not defined in any system header
@@ -40,10 +42,8 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
we extract the pc (JB_PC) that we will land at. The pc is copied into ADDR.
This routine returns true on success */
-extern int
-get_longjmp_target PARAMS ((CORE_ADDR *));
+extern int get_longjmp_target (CORE_ADDR *);
#define GET_LONGJMP_TARGET(ADDR) get_longjmp_target(ADDR)
-#endif /* ifndef TM_I386NW_H */
-
+#endif /* ifndef TM_I386NW_H */
diff --git a/contrib/gdb/gdb/config/i386/tm-i386os9k.h b/contrib/gdb/gdb/config/i386/tm-i386os9k.h
index 2b48641..78fbc21 100644
--- a/contrib/gdb/gdb/config/i386/tm-i386os9k.h
+++ b/contrib/gdb/gdb/config/i386/tm-i386os9k.h
@@ -1,20 +1,22 @@
/* Macro definitions for i386 running under BSD Unix.
- Copyright 1986, 1987, 1989, 1991, 1992, 1993 Free Software Foundation, Inc.
+ Copyright 1986, 1987, 1989, 1991, 1992, 1993, 1994, 1995, 1996
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
#ifndef TM_I386OS9K_H
#define TM_I386OS9K_H 1
@@ -24,7 +26,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/* Number of machine registers */
#undef NUM_REGS
-#define NUM_REGS (16) /* Basic i*86 regs */
+#define NUM_REGS (16) /* Basic i*86 regs */
/* Initializer for an array of names of registers. There should be at least
NUM_REGS strings in this initializer. Any excess ones are simply ignored.
@@ -32,14 +34,14 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
scheme (which is the same as the 386 scheme) and also regmap in the various
*-nat.c files. */
-#undef REGISTER_NAMES
+#undef REGISTER_NAME
#define REGISTER_NAMES { "eax", "ecx", "edx", "ebx", \
"esp", "ebp", "esi", "edi", \
"eip", "eflags", "cs", "ss", \
"ds", "es", "fs", "gs", \
}
-#define DATABASE_REG 3 /* ebx */
+#define DATABASE_REG 3 /* ebx */
/* Amount PC must be decremented by after a breakpoint. This is often the
number of bytes in BREAKPOINT but not always (such as now). */
@@ -60,4 +62,4 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define BELIEVE_PCC_PROMOTION 1
-#endif /* #ifndef TM_I386OS9K_H */
+#endif /* #ifndef TM_I386OS9K_H */
diff --git a/contrib/gdb/gdb/config/i386/tm-i386sco5.h b/contrib/gdb/gdb/config/i386/tm-i386sco5.h
index ffac5b3..e4cb014 100644
--- a/contrib/gdb/gdb/config/i386/tm-i386sco5.h
+++ b/contrib/gdb/gdb/config/i386/tm-i386sco5.h
@@ -1,22 +1,23 @@
/* Macro definitions for GDB on an Intel i386 running SCO Open Server 5.
- Copyright (C) 1998 Free Software Foundation, Inc.
+ Copyright 1998 Free Software Foundation, Inc.
Written by J. Kean Johnston (jkj@sco.com).
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
#ifndef TM_I386SCO5_H
#define TM_I386SCO5_H 1
@@ -51,12 +52,12 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define HAVE_STEPPABLE_WATCHPOINT
#define STOPPED_BY_WATCHPOINT(W) \
- i386_stopped_by_watchpoint (inferior_pid)
+ i386_stopped_by_watchpoint (PIDGET (inferior_ptid))
#define target_insert_watchpoint(addr, len, type) \
- i386_insert_watchpoint (inferior_pid, addr, len, type)
+ i386_insert_watchpoint (PIDGET (inferior_ptid), addr, len, type)
#define target_remove_watchpoint(addr, len, type) \
- i386_remove_watchpoint (inferior_pid, addr, len)
+ i386_remove_watchpoint (PIDGET (inferior_ptid), addr, len)
-#endif /* ifndef TM_I386SCO5_H */
+#endif /* ifndef TM_I386SCO5_H */
diff --git a/contrib/gdb/gdb/config/i386/tm-i386sol2.h b/contrib/gdb/gdb/config/i386/tm-i386sol2.h
index dbd6317..c90e0d4 100644
--- a/contrib/gdb/gdb/config/i386/tm-i386sol2.h
+++ b/contrib/gdb/gdb/config/i386/tm-i386sol2.h
@@ -1,27 +1,42 @@
/* Macro definitions for GDB on an Intel i386 running Solaris 2.
- Copyright (C) 1998 Free Software Foundation, Inc.
+ Copyright 1998, 1999, 2000 Free Software Foundation, Inc.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
#ifndef TM_I386SOL2_H
#define TM_I386SOL2_H 1
+#define HAVE_I387_REGS
#include "i386/tm-i386v4.h"
-
+
+/* We use stabs-in-ELF with the DWARF register numbering scheme. */
+
+#undef STAB_REG_TO_REGNUM
+#define STAB_REG_TO_REGNUM(reg) i386_dwarf_reg_to_regnum ((reg))
+
+/* If the current gcc for for this target does not produce correct
+ debugging information for float parameters, both prototyped and
+ unprototyped, then define this macro. This forces gdb to always
+ assume that floats are passed as doubles and then converted in the
+ callee. */
+
+#define COERCE_FLOAT_TO_DOUBLE(formal, actual) (1)
+
/* Signal handler frames under Solaris 2 are recognized by a return address
of 0xFFFFFFFF, the third parameter on the signal handler stack is
a pointer to an ucontext. */
@@ -35,30 +50,10 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
and for SunPRO 3.0, N_FUN symbols too. */
#define SOFUN_ADDRESS_MAYBE_MISSING
-extern char *sunpro_static_transform_name PARAMS ((char *));
+extern char *sunpro_static_transform_name (char *);
#define STATIC_TRANSFORM_NAME(x) sunpro_static_transform_name (x)
#define IS_STATIC_TRANSFORM_NAME(name) ((name)[0] == '.')
#define FAULTED_USE_SIGINFO
-/* Macros to extract process id and thread id from a composite pid/tid */
-#define PIDGET(pid) ((pid) & 0xffff)
-#define TIDGET(pid) (((pid) >> 16) & 0xffff)
-
-/* Macro to extract carry from given regset. */
-#define PS_FLAG_CARRY 0x1 /* Carry bit in PS */
-#define PROCFS_GET_CARRY(regset) ((regset)[EFL] & PS_FLAG_CARRY)
-
-#ifdef HAVE_THREAD_DB_LIB
-
-extern char *solaris_pid_to_str PARAMS ((int pid));
-#define target_pid_to_str(PID) solaris_pid_to_str (PID)
-
-#else
-
-extern char *procfs_pid_to_str PARAMS ((int pid));
-#define target_pid_to_str(PID) procfs_pid_to_str (PID)
-
-#endif
-
-#endif /* ifndef TM_I386SOL2_H */
+#endif /* ifndef TM_I386SOL2_H */
diff --git a/contrib/gdb/gdb/config/i386/tm-i386v.h b/contrib/gdb/gdb/config/i386/tm-i386v.h
index bb31cb0..d524652 100644
--- a/contrib/gdb/gdb/config/i386/tm-i386v.h
+++ b/contrib/gdb/gdb/config/i386/tm-i386v.h
@@ -1,21 +1,23 @@
/* Macro definitions for i386, Unix System V.
- Copyright 1986, 1987, 1989, 1991, 1992, 1993 Free Software Foundation, Inc.
+ Copyright 1986, 1987, 1989, 1991, 1992, 1993, 1994, 1995, 1998, 1999,
+ 2000, 2001 Free Software Foundation, Inc.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
#ifndef TM_I386V_H
#define TM_I386V_H 1
@@ -31,133 +33,4 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#undef START_INFERIOR_TRAPS_EXPECTED
#define START_INFERIOR_TRAPS_EXPECTED 4
-/* Number of machine registers */
-
-#undef NUM_REGS
-#define NUM_REGS 16
-
-/* Initializer for an array of names of registers.
- There should be NUM_REGS strings in this initializer. */
-
-/* the order of the first 8 registers must match the compiler's
- * numbering scheme (which is the same as the 386 scheme)
- * also, this table must match regmap in i386-pinsn.c.
- */
-
-#undef REGISTER_NAMES
-#define REGISTER_NAMES { "eax", "ecx", "edx", "ebx", \
- "esp", "ebp", "esi", "edi", \
- "eip", "ps", "cs", "ss", \
- "ds", "es", "fs", "gs", \
- }
-
-/* 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 * 4)
-
-/* Index within `registers' of the first byte of the space for
- register N. */
-
-#undef REGISTER_BYTE
-#define REGISTER_BYTE(N) ((N)*4)
-
-/* Number of bytes of storage in the actual machine representation
- for register N. */
-
-#undef REGISTER_RAW_SIZE
-#define REGISTER_RAW_SIZE(N) (4)
-
-/* Number of bytes of storage in the program's representation
- for register N. */
-
-#undef REGISTER_VIRTUAL_SIZE
-#define REGISTER_VIRTUAL_SIZE(N) (4)
-
-/* Largest value REGISTER_RAW_SIZE can have. */
-
-#undef MAX_REGISTER_RAW_SIZE
-#define MAX_REGISTER_RAW_SIZE 4
-
-/* Largest value REGISTER_VIRTUAL_SIZE can have. */
-
-#undef MAX_REGISTER_VIRTUAL_SIZE
-#define MAX_REGISTER_VIRTUAL_SIZE 4
-
-/* Return the GDB type object for the "standard" data type
- of data in register N. */
-/* Perhaps si and di should go here, but potentially they could be
- used for things other than address. */
-
-#undef REGISTER_VIRTUAL_TYPE
-#define REGISTER_VIRTUAL_TYPE(N) \
- ((N) == PC_REGNUM || (N) == FP_REGNUM || (N) == SP_REGNUM ? \
- lookup_pointer_type (builtin_type_void) : builtin_type_int)
-
-/* Store the address of the place in which to copy the structure the
- subroutine will return. This is called from call_function. */
-
-#undef STORE_STRUCT_RETURN
-#define STORE_STRUCT_RETURN(ADDR, SP) \
- { char buf[REGISTER_SIZE]; \
- (SP) -= sizeof (ADDR); \
- store_address (buf, sizeof (ADDR), ADDR); \
- write_memory ((SP), buf, sizeof (ADDR)); }
-
-/* Extract from an array REGBUF containing the (raw) register state
- a function return value of type TYPE, and copy that, in virtual format,
- into VALBUF. */
-
-#undef EXTRACT_RETURN_VALUE
-#define EXTRACT_RETURN_VALUE(TYPE,REGBUF,VALBUF) \
- memcpy ((VALBUF), (REGBUF), TYPE_LENGTH (TYPE))
-
-/* Write into appropriate registers a function return value
- of type TYPE, given in virtual format. */
-
-#undef STORE_RETURN_VALUE
-#define STORE_RETURN_VALUE(TYPE,VALBUF) \
- write_register_bytes (0, VALBUF, TYPE_LENGTH (TYPE))
-
-
-/* Describe the pointer in each stack frame to the previous stack frame
- (its caller). */
-
-/* FRAME_CHAIN takes a frame's nominal address
- and produces the frame's chain-pointer. */
-
-#undef FRAME_CHAIN
-#define FRAME_CHAIN(thisframe) \
- (!inside_entry_file ((thisframe)->pc) ? \
- read_memory_integer ((thisframe)->frame, 4) :\
- 0)
-
-/* Define other aspects of the stack frame. */
-
-/* A macro that tells us whether the function invocation represented
- by FI does not have a frame on the stack associated with it. If it
- does not, FRAMELESS is set to 1, else 0. */
-
-#undef FRAMELESS_FUNCTION_INVOCATION
-#define FRAMELESS_FUNCTION_INVOCATION(FI, FRAMELESS) \
- (FRAMELESS) = frameless_look_for_prologue(FI)
-
-#undef FRAME_SAVED_PC
-#define FRAME_SAVED_PC(FRAME) (read_memory_integer ((FRAME)->frame + 4, 4))
-
-/* Return number of args passed to a frame.
- Can return -1, meaning no way to tell. */
-
-#undef FRAME_NUM_ARGS
-#define FRAME_NUM_ARGS(numargs, fi) (numargs) = -1
-
-#ifdef __STDC__ /* Forward decl's for prototypes */
-struct frame_info;
-struct frame_saved_regs;
-#endif
-
-extern int
-i386_frame_num_args PARAMS ((struct frame_info *));
-
-#endif /* ifndef TM_I386V_H */
+#endif /* ifndef TM_I386V_H */
diff --git a/contrib/gdb/gdb/config/i386/tm-i386v4.h b/contrib/gdb/gdb/config/i386/tm-i386v4.h
index eafff01..2003b96d 100644
--- a/contrib/gdb/gdb/config/i386/tm-i386v4.h
+++ b/contrib/gdb/gdb/config/i386/tm-i386v4.h
@@ -1,28 +1,30 @@
/* Macro definitions for GDB on an Intel i386 running SVR4.
- Copyright (C) 1991, 1994 Free Software Foundation, Inc.
+ Copyright 1991, 1994, 1995, 1998, 1999, 2000
+ Free Software Foundation, Inc.
Written by Fred Fish at Cygnus Support (fnf@cygnus.com)
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
#ifndef TM_I386V4_H
#define TM_I386V4_H 1
/* Pick up most of what we need from the generic i386 target include file. */
-
+#define HAVE_I387_REGS
#include "i386/tm-i386.h"
/* Pick up more stuff from the generic SVR4 host include file. */
@@ -31,7 +33,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/* Use the alternate method of determining valid frame chains. */
-#define FRAME_CHAIN_VALID(fp,fi) alternate_frame_chain_valid (fp, fi)
+#define FRAME_CHAIN_VALID(fp,fi) func_frame_chain_valid (fp, fi)
/* Offsets (in target ints) into jmp_buf. Not defined in any system header
file, so we have to step through setjmp/longjmp with a debugger and figure
@@ -47,15 +49,14 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define JB_ESP 4
#define JB_EDX 5
-#define JB_PC JB_EDX /* Setjmp()'s return PC saved in EDX */
+#define JB_PC JB_EDX /* Setjmp()'s return PC saved in EDX */
/* Figure out where the longjmp will land. Slurp the args out of the stack.
We expect the first arg to be a pointer to the jmp_buf structure from which
we extract the pc (JB_PC) that we will land at. The pc is copied into ADDR.
This routine returns true on success */
-extern int
-get_longjmp_target PARAMS ((CORE_ADDR *));
+extern int get_longjmp_target (CORE_ADDR *);
#define GET_LONGJMP_TARGET(ADDR) get_longjmp_target(ADDR)
@@ -73,6 +74,6 @@ get_longjmp_target PARAMS ((CORE_ADDR *));
/* Saved Pc. Get it from ucontext if within sigtramp. */
#define sigtramp_saved_pc i386v4_sigtramp_saved_pc
-extern CORE_ADDR i386v4_sigtramp_saved_pc PARAMS ((struct frame_info *));
+extern CORE_ADDR i386v4_sigtramp_saved_pc (struct frame_info *);
-#endif /* ifndef TM_I386V4_H */
+#endif /* ifndef TM_I386V4_H */
diff --git a/contrib/gdb/gdb/config/i386/tm-i386v42mp.h b/contrib/gdb/gdb/config/i386/tm-i386v42mp.h
index 81df85b..5671e42 100644
--- a/contrib/gdb/gdb/config/i386/tm-i386v42mp.h
+++ b/contrib/gdb/gdb/config/i386/tm-i386v42mp.h
@@ -1,22 +1,23 @@
/* Macro definitions for GDB on an Intel i386 running SVR4.2MP
- Copyright (C) 1991, 1994 Free Software Foundation, Inc.
+ Copyright 1991, 1994, 1997, 1999, 2000 Free Software Foundation, Inc.
Written by Fred Fish at Cygnus Support (fnf@cygnus.com)
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
#ifndef TM_I386V42MP_H
#define TM_I386V42MP_H 1
@@ -25,20 +26,68 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "i386/tm-i386v4.h"
-/* procfs on this architecture has multiple fds (ctl, as, map, status)
- including a control fd */
+/* define to select for other sysv4.2mp weirdness (see procfs.c) */
-#ifndef HAVE_MULTIPLE_PROC_FDS
-#define HAVE_MULTIPLE_PROC_FDS
+#define UNIXWARE
+
+#if 0
+/* The following macros extract process and lwp/thread ids from a
+ composite id.
+
+ For consistency with UnixWare core files, allocate bits 0-15 for
+ process ids and bits 16 and up for lwp ids. Reserve bit 31 for
+ negative return values to indicate exceptions, and use bit 30 as a
+ flag to indicate a user-mode thread, leaving 14 bits for lwp
+ ids. */
+
+/* Number of bits in composite id allocated to process number. */
+#define PIDBITS 16
+
+/* Return the process id stored in composite PID. */
+#define PIDGET(PID) (((PID) & ((1 << PIDBITS) - 1)))
+
+/* Return the thread or lwp id stored in composite PID. */
+#define TIDGET(PID) (((PID) & 0x3fffffff) >> PIDBITS)
+#define LIDGET(PID) TIDGET(PID)
+
+/* Construct a composite id from lwp LID and the process portion of
+ composite PID. */
+#define MERGEPID(PID, LID) (PIDGET(PID) | ((LID) << PIDBITS))
+#define MKLID(PID, LID) MERGEPID(PID, LID)
+
+/* Construct a composite id from thread TID and the process portion of
+ composite PID. */
+#define MKTID(PID, TID) (MERGEPID(PID, TID) | 0x40000000)
+
+/* Return whether PID contains a user-space thread id. */
+#define ISTID(PID) ((PID) & 0x40000000)
#endif
-/* procfs on this architecture communicates with read/write instead
- of ioctl */
+/* New definitions of the ptid stuff. Due to the way the
+ code is structured in uw-thread.c, I'm overloading the thread id
+ and lwp id onto the lwp field. The tid field is used to indicate
+ whether the lwp is a tid or not.
+
+ FIXME: Check that core file support is not broken. (See original
+ #if 0'd comments above.)
+ FIXME: Restructure uw-thread.c so that the struct ptid fields
+ can be used as intended. */
-#define PROCFS_USE_READ_WRITE
+/* Return the process id stored in composite PID. */
+#define PIDGET(PID) (ptid_get_pid (PID))
-/* define to select for other sysv4.2mp weirdness */
+/* Return the thread or lwp id stored in composite PID. */
+#define TIDGET(PID) (ptid_get_lwp (PID))
+#define LIDGET(PID) TIDGET(PID)
-#define UNIXWARE
+#define MERGEPID(PID, LID) (ptid_build ((PID), (LID), 0))
+#define MKLID(PID, LID) (ptid_build ((PID), (LID), 0))
+
+/* Construct a composite id from thread TID and the process portion of
+ composite PID. */
+#define MKTID(PID, TID) (ptid_build ((PID), (TID), 1))
+
+/* Return whether PID contains a user-space thread id. */
+#define ISTID(PID) (ptid_get_tid (PID))
-#endif /* ifndef TM_I386V42MP_H */
+#endif /* ifndef TM_I386V42MP_H */
diff --git a/contrib/gdb/gdb/config/i386/tm-linux.h b/contrib/gdb/gdb/config/i386/tm-linux.h
index 417d151..5c549b9 100644
--- a/contrib/gdb/gdb/config/i386/tm-linux.h
+++ b/contrib/gdb/gdb/config/i386/tm-linux.h
@@ -1,38 +1,130 @@
/* Definitions to target GDB to GNU/Linux on 386.
- Copyright 1992, 1993 Free Software Foundation, Inc.
-This file is part of GDB.
+ Copyright 1992, 1993, 1995, 1996, 1998, 1999, 2000, 2001, 2002 Free
+ Software Foundation, Inc.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This file is part of GDB.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is 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.
-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 program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
#ifndef TM_LINUX_H
#define TM_LINUX_H
-/* FIXME: If nothing else gets added to this file, it could be removed
- and configure could just use tm-i386.h instead. -fnf */
+#define I386_GNULINUX_TARGET
+#define HAVE_I387_REGS
+#ifdef HAVE_PTRACE_GETFPXREGS
+#define HAVE_SSE_REGS
+#endif
#include "i386/tm-i386.h"
+#include "tm-linux.h"
+
+/* Register number for the "orig_eax" pseudo-register. If this
+ pseudo-register contains a value >= 0 it is interpreted as the
+ system call number that the kernel is supposed to restart. */
+#define I386_LINUX_ORIG_EAX_REGNUM (NUM_GREGS + NUM_FREGS + NUM_SSE_REGS)
+
+/* Adjust a few macros to deal with this extra register. */
+
+#undef NUM_REGS
+#define NUM_REGS (NUM_GREGS + NUM_FREGS + NUM_SSE_REGS + 1)
+
+#undef MAX_NUM_REGS
+#define MAX_NUM_REGS (16 + 16 + 9 + 1)
+
+#undef REGISTER_BYTES
+#define REGISTER_BYTES \
+ (SIZEOF_GREGS + SIZEOF_FPU_REGS + SIZEOF_FPU_CTRL_REGS + SIZEOF_SSE_REGS + 4)
-/* Offset to saved PC in sigcontext, from <linux/signal.h>. */
-#define SIGCONTEXT_PC_OFFSET 38
+#undef REGISTER_NAME
+#define REGISTER_NAME(reg) i386_linux_register_name ((reg))
+extern char *i386_linux_register_name (int reg);
-/* We need this file for the SOLIB_TRAMPOLINE stuff. */
+#undef REGISTER_BYTE
+#define REGISTER_BYTE(reg) i386_linux_register_byte ((reg))
+extern int i386_linux_register_byte (int reg);
-#include "tm-sysv4.h"
+#undef REGISTER_RAW_SIZE
+#define REGISTER_RAW_SIZE(reg) i386_linux_register_raw_size ((reg))
+extern int i386_linux_register_raw_size (int reg);
+
+/* GNU/Linux ELF uses stabs-in-ELF with the DWARF register numbering
+ scheme by default, so we must redefine STAB_REG_TO_REGNUM. This
+ messes up the floating-point registers for a.out, but there is not
+ much we can do about that. */
+#undef STAB_REG_TO_REGNUM
+#define STAB_REG_TO_REGNUM(reg) i386_dwarf_reg_to_regnum ((reg))
+
+/* Use target_specific function to define link map offsets. */
+extern struct link_map_offsets *i386_linux_svr4_fetch_link_map_offsets (void);
+#define SVR4_FETCH_LINK_MAP_OFFSETS() i386_linux_svr4_fetch_link_map_offsets ()
/* The following works around a problem with /usr/include/sys/procfs.h */
#define sys_quotactl 1
-#endif /* #ifndef TM_LINUX_H */
+/* When the i386 Linux kernel calls a signal handler, the return
+ address points to a bit of code on the stack. These definitions
+ are used to identify this bit of code as a signal trampoline in
+ order to support backtracing through calls to signal handlers. */
+
+#define IN_SIGTRAMP(pc, name) i386_linux_in_sigtramp (pc, name)
+extern int i386_linux_in_sigtramp (CORE_ADDR, char *);
+
+#undef FRAME_CHAIN
+#define FRAME_CHAIN(frame) i386_linux_frame_chain (frame)
+extern CORE_ADDR i386_linux_frame_chain (struct frame_info *frame);
+
+#undef FRAME_SAVED_PC
+#define FRAME_SAVED_PC(frame) i386_linux_frame_saved_pc (frame)
+extern CORE_ADDR i386_linux_frame_saved_pc (struct frame_info *frame);
+
+#undef SAVED_PC_AFTER_CALL
+#define SAVED_PC_AFTER_CALL(frame) i386_linux_saved_pc_after_call (frame)
+extern CORE_ADDR i386_linux_saved_pc_after_call (struct frame_info *);
+
+#define TARGET_WRITE_PC(pc, ptid) i386_linux_write_pc (pc, ptid)
+extern void i386_linux_write_pc (CORE_ADDR pc, ptid_t ptid);
+
+/* When we call a function in a shared library, and the PLT sends us
+ into the dynamic linker to find the function's real address, we
+ need to skip over the dynamic linker call. This function decides
+ when to skip, and where to skip to. See the comments for
+ SKIP_SOLIB_RESOLVER at the top of infrun.c. */
+#define SKIP_SOLIB_RESOLVER i386_linux_skip_solib_resolver
+extern CORE_ADDR i386_linux_skip_solib_resolver (CORE_ADDR pc);
+
+/* N_FUN symbols in shared libaries have 0 for their values and need
+ to be relocated. */
+#define SOFUN_ADDRESS_MAYBE_MISSING
+
+
+/* Support for longjmp. */
+
+/* Details about jmp_buf. It's supposed to be an array of integers. */
+
+#define JB_ELEMENT_SIZE 4 /* Size of elements in jmp_buf. */
+#define JB_PC 5 /* Array index of saved PC. */
+
+/* Figure out where the longjmp will land. Slurp the args out of the
+ stack. We expect the first arg to be a pointer to the jmp_buf
+ structure from which we extract the pc (JB_PC) that we will land
+ at. The pc is copied into ADDR. This routine returns true on
+ success. */
+
+#define GET_LONGJMP_TARGET(addr) get_longjmp_target (addr)
+extern int get_longjmp_target (CORE_ADDR *addr);
+
+#endif /* #ifndef TM_LINUX_H */
diff --git a/contrib/gdb/gdb/config/i386/tm-nbsd.h b/contrib/gdb/gdb/config/i386/tm-nbsd.h
index cf5159f..ff67a5e 100644
--- a/contrib/gdb/gdb/config/i386/tm-nbsd.h
+++ b/contrib/gdb/gdb/config/i386/tm-nbsd.h
@@ -1,42 +1,70 @@
/* Macro definitions for i386 running under NetBSD.
- Copyright 1994 Free Software Foundation, Inc.
+ Copyright 1994, 1996, 2000, 2002 Free Software Foundation, Inc.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
#ifndef TM_NBSD_H
#define TM_NBSD_H
-#include "i386/tm-i386bsd.h"
-#include "tm-nbsd.h"
+#define HAVE_I387_REGS
+#define HAVE_SSE_REGS
+
+#include "i386/tm-i386.h"
+#include "config/tm-nbsd.h"
+
+extern use_struct_convention_fn i386nbsd_use_struct_convention;
+#define USE_STRUCT_CONVENTION(gcc_p, type) \
+ i386nbsd_use_struct_convention(gcc_p, type)
-#undef NUM_REGS
-#define NUM_REGS 16
#define JB_ELEMENT_SIZE sizeof(int) /* jmp_buf[_JBLEN] is array of ints */
-#define JB_PC 0 /* Setjmp()'s return PC saved here */
+#define JB_PC 0 /* Setjmp()'s return PC saved here */
/* Figure out where the longjmp will land. Slurp the args out of the stack.
We expect the first arg to be a pointer to the jmp_buf structure from which
we extract the pc (JB_PC) that we will land at. The pc is copied into ADDR.
This routine returns true on success */
-extern int
-get_longjmp_target PARAMS ((CORE_ADDR *));
+extern int get_longjmp_target (CORE_ADDR *);
#define GET_LONGJMP_TARGET(ADDR) get_longjmp_target(ADDR)
+
+/* Support for signal handlers. */
+
+#define IN_SIGTRAMP(pc, name) i386bsd_in_sigtramp (pc, name)
+extern int i386bsd_in_sigtramp (CORE_ADDR pc, char *name);
+
+/* These defines allow the recognition of sigtramps as a function name
+ <sigtramp>.
+
+ FIXME: kettenis/2001-07-13: These should be added to the target
+ vector and turned into functions when we go "multi-arch". */
+
+#define SIGTRAMP_START(pc) i386bsd_sigtramp_start
+#define SIGTRAMP_END(pc) i386bsd_sigtramp_end
+extern CORE_ADDR i386bsd_sigtramp_start;
+extern CORE_ADDR i386bsd_sigtramp_end;
+
+/* Override FRAME_SAVED_PC to enable the recognition of signal handlers. */
+
+#undef FRAME_SAVED_PC
+#define FRAME_SAVED_PC(frame) i386bsd_frame_saved_pc (frame)
+extern CORE_ADDR i386bsd_frame_saved_pc (struct frame_info *frame);
+
#endif /* TM_NBSD_H */
diff --git a/contrib/gdb/gdb/config/i386/tm-nbsdelf.h b/contrib/gdb/gdb/config/i386/tm-nbsdelf.h
new file mode 100644
index 0000000..4d802c5
--- /dev/null
+++ b/contrib/gdb/gdb/config/i386/tm-nbsdelf.h
@@ -0,0 +1,28 @@
+/* Macro definitions for i386 running under NetBSD.
+ Copyright 2000 Free Software Foundation, Inc.
+
+ This file is part of GDB.
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
+
+#ifndef TM_NBSDELF_H
+#define TM_NBSDELF_H
+
+#include "i386/tm-nbsd.h"
+
+#undef USE_STRUCT_CONVENTION
+
+#endif /* TM_NBSD_H */
diff --git a/contrib/gdb/gdb/config/i386/tm-obsd.h b/contrib/gdb/gdb/config/i386/tm-obsd.h
new file mode 100644
index 0000000..d26b03b
--- /dev/null
+++ b/contrib/gdb/gdb/config/i386/tm-obsd.h
@@ -0,0 +1,77 @@
+/* Target-dependent definitions for OpenBSD/i386.
+ Copyright 2001 Free Software Foundation, Inc.
+
+ This file is part of GDB.
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
+
+#ifndef TM_OBSD_H
+#define TM_OBSD_H
+
+#define HAVE_I387_REGS
+#include "i386/tm-i386.h"
+
+/* OpenBSD uses the old gcc convention for struct returns. */
+
+#define USE_STRUCT_CONVENTION(gcc_p, type) \
+ generic_use_struct_convention (1, type)
+
+
+/* Support for longjmp. */
+
+/* Details about jmp_buf. It's supposed to be an array of integers. */
+
+#define JB_ELEMENT_SIZE 4 /* Size of elements in jmp_buf. */
+#define JB_PC 0 /* Array index of saved PC. */
+
+/* Figure out where the longjmp will land. Store the address that
+ longjmp will jump to in *ADDR, and return non-zero if successful. */
+
+#define GET_LONGJMP_TARGET(addr) get_longjmp_target (addr)
+extern int get_longjmp_target (CORE_ADDR *addr);
+
+
+/* Support for signal handlers. */
+
+#define IN_SIGTRAMP(pc, name) i386bsd_in_sigtramp (pc, name)
+extern int i386bsd_in_sigtramp (CORE_ADDR pc, char *name);
+
+/* These defines allow the recognition of sigtramps as a function name
+ <sigtramp>.
+
+ FIXME: kettenis/2001-07-13: These should be added to the target
+ vector and turned into functions when we go "multi-arch". */
+
+#define SIGTRAMP_START(pc) i386bsd_sigtramp_start
+#define SIGTRAMP_END(pc) i386bsd_sigtramp_end
+extern CORE_ADDR i386bsd_sigtramp_start;
+extern CORE_ADDR i386bsd_sigtramp_end;
+
+/* Override FRAME_SAVED_PC to enable the recognition of signal handlers. */
+
+#undef FRAME_SAVED_PC
+#define FRAME_SAVED_PC(frame) i386bsd_frame_saved_pc (frame)
+extern CORE_ADDR i386bsd_frame_saved_pc (struct frame_info *frame);
+
+
+/* Shared library support. */
+
+/* Return non-zero if we are in a shared library trampoline code stub. */
+
+#define IN_SOLIB_CALL_TRAMPOLINE(pc, name) \
+ (name && !strcmp(name, "_DYNAMIC"))
+
+#endif /* tm-obsd.h */
diff --git a/contrib/gdb/gdb/config/i386/tm-ptx.h b/contrib/gdb/gdb/config/i386/tm-ptx.h
index c9f67d7..2a1731a 100644
--- a/contrib/gdb/gdb/config/i386/tm-ptx.h
+++ b/contrib/gdb/gdb/config/i386/tm-ptx.h
@@ -1,23 +1,25 @@
/* Target machine definitions for GDB on a Sequent Symmetry under ptx
with Weitek 1167 and i387 support.
- Copyright 1986, 1987, 1989, 1991, 1992, 1993 Free Software Foundation, Inc.
+ Copyright 1986, 1987, 1989, 1991, 1992, 1993, 1994, 1995, 2000
+ Free Software Foundation, Inc.
Symmetry version by Jay Vosburgh (fubar@sequent.com).
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
#ifndef TM_PTX_H
#define TM_PTX_H 1
@@ -48,8 +50,8 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define DECR_PC_AFTER_BREAK 0
#if 0
- --- this code can't be used unless we know we are running native,
- since it uses host specific ptrace calls.
+-- -this code can 't be used unless we know we are running native,
+since it uses host specific ptrace calls.
/* code for 80387 fpu. Functions are from i386-dep.c, copied into
* symm-dep.c.
*/
@@ -67,7 +69,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
scheme (which is the same as the 386 scheme) and also regmap in the various
*-nat.c files. */
-#undef REGISTER_NAMES
+#undef REGISTER_NAME
#define REGISTER_NAMES { "eax", "ecx", "edx", "ebx", \
"esp", "ebp", "esi", "edi", \
"eip", "eflags", "st0", "st1", \
@@ -138,8 +140,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define REGISTER_U_ADDR(addr, blockend, regno) \
{ (addr) = ptx_register_u_addr((blockend), (regno)); }
-extern int
-ptx_register_u_addr PARAMS ((int, int));
+extern int ptx_register_u_addr (int, int);
/* Total amount of space needed to store our copies of the machine's
register state, the array `registers'. 10 i*86 registers, 8 i387
@@ -179,10 +180,10 @@ ptx_register_u_addr PARAMS ((int, int));
((N < ST0_REGNUM) ? 0 : \
(N < FP1_REGNUM) ? 1 : \
0)
-
+
/* Convert data from raw format for register REGNUM
to virtual format for register REGNUM. */
-extern const struct floatformat floatformat_i387_ext; /* from floatformat.h */
+extern const struct floatformat floatformat_i387_ext; /* from floatformat.h */
#undef REGISTER_CONVERT_TO_VIRTUAL
#define REGISTER_CONVERT_TO_VIRTUAL(REGNUM,TYPE,FROM,TO) \
@@ -190,7 +191,7 @@ extern const struct floatformat floatformat_i387_ext; /* from floatformat.h */
(REGNUM < FP1_REGNUM) ? (void)floatformat_to_double(&floatformat_i387_ext, \
(FROM),(TO)) : \
(void)memcpy ((TO), (FROM), 4))
-
+
/* Convert data from virtual format for register REGNUM
to raw format for register REGNUM. */
@@ -224,9 +225,9 @@ extern const struct floatformat floatformat_i387_ext; /* from floatformat.h */
symmetry_extract_return_value(TYPE, REGBUF, VALBUF)
/*
-#undef FRAME_FIND_SAVED_REGS
-#define FRAME_FIND_SAVED_REGS(frame_info, frame_saved_regs) \
-{ ptx_frame_find_saved_regs((frame_info), &(frame_saved_regs)); }
-*/
+ #undef FRAME_FIND_SAVED_REGS
+ #define FRAME_FIND_SAVED_REGS(frame_info, frame_saved_regs) \
+ { ptx_frame_find_saved_regs((frame_info), &(frame_saved_regs)); }
+ */
-#endif /* ifndef TM_PTX_H */
+#endif /* ifndef TM_PTX_H */
diff --git a/contrib/gdb/gdb/config/i386/tm-ptx4.h b/contrib/gdb/gdb/config/i386/tm-ptx4.h
index a576acc..1f221ba 100644
--- a/contrib/gdb/gdb/config/i386/tm-ptx4.h
+++ b/contrib/gdb/gdb/config/i386/tm-ptx4.h
@@ -1,23 +1,25 @@
/* Target machine definitions for GDB on a Sequent Symmetry under ptx
with Weitek 1167 and i387 support.
- Copyright 1986, 1987, 1989, 1991, 1992, 1993 Free Software Foundation, Inc.
+ Copyright 1986, 1987, 1989, 1991, 1992, 1993, 1994
+ Free Software Foundation, Inc.
Symmetry version by Jay Vosburgh (fubar@sequent.com).
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
#define SEQUENT_PTX4
diff --git a/contrib/gdb/gdb/config/i386/tm-symmetry.h b/contrib/gdb/gdb/config/i386/tm-symmetry.h
index 11931d4..7828181 100644
--- a/contrib/gdb/gdb/config/i386/tm-symmetry.h
+++ b/contrib/gdb/gdb/config/i386/tm-symmetry.h
@@ -1,28 +1,32 @@
/* Target machine definitions for GDB on a Sequent Symmetry under dynix 3.0,
with Weitek 1167 and i387 support.
- Copyright 1986, 1987, 1989, 1991, 1992, 1993, 1994
+ Copyright 1986, 1987, 1989, 1991, 1992, 1993, 1994, 1995
Free Software Foundation, Inc.
Symmetry version by Jay Vosburgh (fubar@sequent.com).
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
#ifndef TM_SYMMETRY_H
#define TM_SYMMETRY_H 1
+#include "regcache.h"
+#include "doublest.h"
+
/* I don't know if this will work for cross-debugging, even if you do get
a copy of the right include file. */
#include <machine/reg.h>
@@ -40,7 +44,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#if 0
/* --- this code can't be used unless we know we are running native,
- since it uses host specific ptrace calls. */
+ since it uses host specific ptrace calls. */
/* code for 80387 fpu. Functions are from i386-dep.c, copied into
* symm-dep.c.
*/
@@ -62,7 +66,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
break mysteriously for no apparent reason. Also note that the st(0)...
st(7) 387 registers are represented as st0...st7. */
-#undef REGISTER_NAMES
+#undef REGISTER_NAME
#define REGISTER_NAMES { "eax", "edx", "ecx", "st0", "st1", \
"ebx", "esi", "edi", "st2", "st3", \
"st4", "st5", "st6", "st7", "esp", \
@@ -101,16 +105,16 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/* Get %fp2 - %fp31 by addition, since they are contiguous */
#undef SP_REGNUM
-#define SP_REGNUM 14 /* (usp) Contains address of top of stack */
+#define SP_REGNUM 14 /* (usp) Contains address of top of stack */
#define ESP_REGNUM 14
#undef FP_REGNUM
-#define FP_REGNUM 15 /* (ebp) Contains address of executing stack frame */
+#define FP_REGNUM 15 /* (ebp) Contains address of executing stack frame */
#define EBP_REGNUM 15
#undef PC_REGNUM
-#define PC_REGNUM 16 /* (eip) Contains program counter */
+#define PC_REGNUM 16 /* (eip) Contains program counter */
#define EIP_REGNUM 16
#undef PS_REGNUM
-#define PS_REGNUM 17 /* (ps) Contains processor status */
+#define PS_REGNUM 17 /* (ps) Contains processor status */
#define EFLAGS_REGNUM 17
/*
@@ -264,8 +268,8 @@ switch (regno) { \
#undef REGISTER_CONVERT_TO_VIRTUAL
#define REGISTER_CONVERT_TO_VIRTUAL(REGNUM,TYPE,FROM,TO) \
{ \
- double val; \
- floatformat_to_double (&floatformat_i387_ext, (FROM), &val); \
+ DOUBLEST val; \
+ floatformat_to_doublest (&floatformat_i387_ext, (FROM), &val); \
store_floating ((TO), TYPE_LENGTH (TYPE), val); \
}
@@ -275,8 +279,8 @@ switch (regno) { \
#undef REGISTER_CONVERT_TO_RAW
#define REGISTER_CONVERT_TO_RAW(TYPE,REGNUM,FROM,TO) \
{ \
- double val = extract_floating ((FROM), TYPE_LENGTH (TYPE)); \
- floatformat_from_double (&floatformat_i387_ext, &val, (TO)); \
+ DOUBLEST val = extract_floating ((FROM), TYPE_LENGTH (TYPE)); \
+ floatformat_from_doublest (&floatformat_i387_ext, &val, (TO)); \
}
/* Return the GDB type object for the "standard" data type
@@ -296,6 +300,7 @@ switch (regno) { \
passes it on the stack. gcc should be fixed in future versions to
adopt native cc conventions. */
+#undef PUSH_ARGUMENTS
#undef STORE_STRUCT_RETURN
#define STORE_STRUCT_RETURN(ADDR, SP) write_register(0, (ADDR))
@@ -317,5 +322,4 @@ switch (regno) { \
/* Offset to saved PC in sigcontext, from <signal.h>. */
#define SIGCONTEXT_PC_OFFSET 16
-#endif /* ifndef TM_SYMMETRY_H */
-
+#endif /* ifndef TM_SYMMETRY_H */
diff --git a/contrib/gdb/gdb/config/i386/tm-vxworks.h b/contrib/gdb/gdb/config/i386/tm-vxworks.h
new file mode 100644
index 0000000..6434a6e
--- /dev/null
+++ b/contrib/gdb/gdb/config/i386/tm-vxworks.h
@@ -0,0 +1,28 @@
+/* Target machine description for VxWorks on the 80[3456]86,
+ for GDB, the GNU debugger.
+ Copyright 1999 Free Software Foundation, Inc.
+
+ This file is part of GDB.
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
+
+#ifndef TM_VXWORKS_H
+#define TM_VXWORKS_H
+
+#include "i386/tm-i386v.h"
+#include "tm-vxworks.h"
+
+#endif /* ifndef TM_VXWORKS_H */
diff --git a/contrib/gdb/gdb/config/i386/vxworks.mt b/contrib/gdb/gdb/config/i386/vxworks.mt
new file mode 100644
index 0000000..a14aacc
--- /dev/null
+++ b/contrib/gdb/gdb/config/i386/vxworks.mt
@@ -0,0 +1,3 @@
+# Target: i386 running VxWorks
+TDEPFILES= i386-tdep.o i387-tdep.o
+TM_FILE= tm-vxworks.h
diff --git a/contrib/gdb/gdb/config/i386/x86-64linux.mh b/contrib/gdb/gdb/config/i386/x86-64linux.mh
new file mode 100644
index 0000000..a0a192c
--- /dev/null
+++ b/contrib/gdb/gdb/config/i386/x86-64linux.mh
@@ -0,0 +1,11 @@
+# Host: AMD x86-64 running GNU/Linux
+
+XM_FILE= xm-i386.h
+
+NAT_FILE= nm-x86-64.h
+NATDEPFILES= infptrace.o inftarg.o fork-child.o corelow.o \
+ core-aout.o i386-nat.o x86-64-linux-nat.o \
+ i387-nat.o proc-service.o thread-db.o lin-lwp.o \
+ linux-proc.o gcore.o
+
+LOADLIBES = -ldl -rdynamic
diff --git a/contrib/gdb/gdb/config/i386/x86-64linux.mt b/contrib/gdb/gdb/config/i386/x86-64linux.mt
new file mode 100644
index 0000000..1f3a796
--- /dev/null
+++ b/contrib/gdb/gdb/config/i386/x86-64linux.mt
@@ -0,0 +1,5 @@
+# Target: AMD x86-64 running GNU/Linux
+TDEPFILES= x86-64-tdep.o x86-64-linux-tdep.o i387-tdep.o dwarf2cfi.o \
+ solib.o solib-svr4.o solib-legacy.o
+
+## OBSOLETE ## GDBSERVER_DEPFILES= low-linux.o
diff --git a/contrib/gdb/gdb/config/i386/xm-cygwin.h b/contrib/gdb/gdb/config/i386/xm-cygwin.h
index f0b8227..6470727 100644
--- a/contrib/gdb/gdb/config/i386/xm-cygwin.h
+++ b/contrib/gdb/gdb/config/i386/xm-cygwin.h
@@ -1,34 +1,24 @@
/* Definitions for hosting on WIN32, for GDB.
- Copyright 1995, 1996, 1997, 1998 Free Software Foundation, Inc.
+ Copyright 1995, 1996, 1997, 1998, 2001 Free Software Foundation, Inc.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
-
-#define HOST_BYTE_ORDER LITTLE_ENDIAN
+ 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 "fopen-bin.h"
-#define GDBINIT_FILENAME "gdb.ini"
-
-#define SLASH_P(X) ((X)=='\\' || (X) == '/')
-#define ROOTED_P(X) ((SLASH_P((X)[0]))|| ((X)[1] ==':'))
-#define SLASH_CHAR '/'
-#define SLASH_STRING "/"
-
/* Define this if source files use \r\n rather than just \n. */
#define CRLF_SOURCE_FILES
-
-#define HAVE_SIGSETMASK 0
diff --git a/contrib/gdb/gdb/config/i386/xm-go32.h b/contrib/gdb/gdb/config/i386/xm-go32.h
index 0797833..dead9f6 100644
--- a/contrib/gdb/gdb/config/i386/xm-go32.h
+++ b/contrib/gdb/gdb/config/i386/xm-go32.h
@@ -1,31 +1,26 @@
-/* Definitions for hosting on GO32, for GDB.
- Copyright 1991, 1992 Free Software Foundation, Inc.
+/* Host-dependent definitions for Intel x86 running DJGPP.
+ Copyright 1993-1996 Free Software Foundation, Inc.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
-#define HOST_BYTE_ORDER LITTLE_ENDIAN
+#include "i386/xm-i386.h"
#include "fopen-bin.h"
-/* Define this lseek(n) != nth byte of file */
-#define LSEEK_NOT_LINEAR
-
-#define CANT_FORK
-
-#undef QUIT
-#define QUIT { pollquit(); }
-
#define GDBINIT_FILENAME "gdb.ini"
+#define CRLF_SOURCE_FILES
+#define DIRNAME_SEPARATOR ';'
diff --git a/contrib/gdb/gdb/config/i386/xm-i386.h b/contrib/gdb/gdb/config/i386/xm-i386.h
new file mode 100644
index 0000000..151e7a6
--- /dev/null
+++ b/contrib/gdb/gdb/config/i386/xm-i386.h
@@ -0,0 +1,30 @@
+/* Host-dependent definitions for i386.
+ Copyright 2001 Free Software Foundation, Inc.
+
+ This file is part of GDB.
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
+
+#ifndef XM_I386_H
+#define XM_I386_H
+
+#include "floatformat.h"
+
+#define HOST_FLOAT_FORMAT &floatformat_ieee_single_little
+#define HOST_DOUBLE_FORMAT &floatformat_ieee_double_little
+#define HOST_LONG_DOUBLE_FORMAT &floatformat_i387_ext
+
+#endif /* XM_386_H */
diff --git a/contrib/gdb/gdb/config/i386/xm-i386aix.h b/contrib/gdb/gdb/config/i386/xm-i386aix.h
index 652a149..842eadf 100644
--- a/contrib/gdb/gdb/config/i386/xm-i386aix.h
+++ b/contrib/gdb/gdb/config/i386/xm-i386aix.h
@@ -1,33 +1,29 @@
/* Macro defintions for AIX PS/2 (i386)
Copyright 1986, 1987, 1989, 1992, 1993 Free Software Foundation, Inc.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
/*
* Changed for IBM AIX ps/2 by Minh Tran Le (tranle@intellicorp.com)
- * Revision: 23-Oct-92 17:42:49
+ * Revision: 23-Oct-92 17:42:49
*/
#include "i386/xm-i386v.h"
#undef HAVE_TERMIO
#define HAVE_SGTTY
-
-#include <limits.h>
-
-/* Use setpgid instead of setpgrp on AIX */
-#define NEED_POSIX_SETPGID
diff --git a/contrib/gdb/gdb/config/i386/xm-i386bsd.h b/contrib/gdb/gdb/config/i386/xm-i386bsd.h
index e5c4c89..ca0ffb2 100644
--- a/contrib/gdb/gdb/config/i386/xm-i386bsd.h
+++ b/contrib/gdb/gdb/config/i386/xm-i386bsd.h
@@ -1,22 +1,22 @@
/* Host-dependent definitions for Intel 386 running BSD Unix, for GDB.
- Copyright 1986, 1987, 1989, 1992 Free Software Foundation, Inc.
+ Copyright 1986, 1987, 1989, 1992, 1995, 1996
+ Free Software Foundation, Inc.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
-#define HOST_BYTE_ORDER LITTLE_ENDIAN
-
-#include <machine/limits.h> /* for INT_MIN */
+#include <machine/limits.h> /* for INT_MIN */
diff --git a/contrib/gdb/gdb/config/i386/xm-i386gnu.h b/contrib/gdb/gdb/config/i386/xm-i386gnu.h
index 60307b2..711aeeb 100644
--- a/contrib/gdb/gdb/config/i386/xm-i386gnu.h
+++ b/contrib/gdb/gdb/config/i386/xm-i386gnu.h
@@ -1,23 +1,25 @@
/* Definitions to make GDB run on the GNU Hurd on an Intel 386
- Copyright (C) 1986, 1987, 1989, 1991 Free Software Foundation, Inc.
+ Copyright 1986, 1987, 1989, 1991, 1996, 2000
+ Free Software Foundation, Inc.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
-#define HOST_BYTE_ORDER LITTLE_ENDIAN
+#define HOST_LONG_DOUBLE_FORMAT &floatformat_i387_ext
/* Do implement the attach and detach commands. */
#define ATTACH_DETACH 1
diff --git a/contrib/gdb/gdb/config/i386/xm-i386m3.h b/contrib/gdb/gdb/config/i386/xm-i386m3.h
index b667409..f25b389 100644
--- a/contrib/gdb/gdb/config/i386/xm-i386m3.h
+++ b/contrib/gdb/gdb/config/i386/xm-i386m3.h
@@ -1,23 +1,23 @@
/* Definitions to make GDB run on Mach 3 on an Intel 386
- Copyright (C) 1986, 1987, 1989, 1991 Free Software Foundation, Inc.
+ Copyright 1986, 1987, 1989, 1991, 1993, 1994, 1996
+ Free Software Foundation, Inc.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
-
-#define HOST_BYTE_ORDER LITTLE_ENDIAN
+ 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. */
/* Do implement the attach and detach commands. */
#define ATTACH_DETACH 1
diff --git a/contrib/gdb/gdb/config/i386/xm-i386mach.h b/contrib/gdb/gdb/config/i386/xm-i386mach.h
index eb47bfb..e0a5d65 100644
--- a/contrib/gdb/gdb/config/i386/xm-i386mach.h
+++ b/contrib/gdb/gdb/config/i386/xm-i386mach.h
@@ -1,23 +1,23 @@
/* Definitions to make GDB run on Mach on an Intel 386
- Copyright (C) 1986, 1987, 1989, 1991, 1992 Free Software Foundation, Inc.
+ Copyright 1986, 1987, 1989, 1991, 1992, 1994, 1996, 2001
+ Free Software Foundation, Inc.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
-
-#define HOST_BYTE_ORDER LITTLE_ENDIAN
+ 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 is the amount to subtract from u.u_ar0
to get the offset in the core file of the register values. */
@@ -26,5 +26,3 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/* <errno.h> only defines this if __STDC__!!! */
extern int errno;
-
-extern char *strdup();
diff --git a/contrib/gdb/gdb/config/i386/xm-i386mk.h b/contrib/gdb/gdb/config/i386/xm-i386mk.h
index 661c9cb..cbf6271 100644
--- a/contrib/gdb/gdb/config/i386/xm-i386mk.h
+++ b/contrib/gdb/gdb/config/i386/xm-i386mk.h
@@ -1,21 +1,22 @@
/* Definitions to make GDB run on Mach 3 OSF 1/MK on an Intel 386
- Copyright (C) 1992 Free Software Foundation, Inc.
+ Copyright 1992, 1993, 1998 Free Software Foundation, Inc.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
#define HAVE_TERMIO 1
diff --git a/contrib/gdb/gdb/config/i386/xm-i386sco.h b/contrib/gdb/gdb/config/i386/xm-i386sco.h
index 31fa7e6..920ebbb 100644
--- a/contrib/gdb/gdb/config/i386/xm-i386sco.h
+++ b/contrib/gdb/gdb/config/i386/xm-i386sco.h
@@ -1,21 +1,22 @@
/* Macro defintions for i386, running SCO Unix System V/386 3.2.
- Copyright (C) 1989 Free Software Foundation, Inc.
+ Copyright 1989, 1993, 1995 Free Software Foundation, Inc.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
/* In 3.2v4 <sys/user.h> requires on <sys/dir.h>. */
#include <sys/types.h>
@@ -37,6 +38,3 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
So we use dots instead. This item must be coordinated with G++. */
#undef CPLUS_MARKER
#define CPLUS_MARKER '.'
-
-/* Use setpgid instead of setpgrp on SCO */
-#define NEED_POSIX_SETPGID
diff --git a/contrib/gdb/gdb/config/i386/xm-i386v.h b/contrib/gdb/gdb/config/i386/xm-i386v.h
index 480dfd6..1c32905 100644
--- a/contrib/gdb/gdb/config/i386/xm-i386v.h
+++ b/contrib/gdb/gdb/config/i386/xm-i386v.h
@@ -2,35 +2,34 @@
Copyright 1986, 1987, 1989, 1992 Free Software Foundation, Inc.
Changes for 80386 by Pace Willisson (pace@prep.ai.mit.edu), July 1988.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
-
-#define HOST_BYTE_ORDER LITTLE_ENDIAN
+ 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. */
/* I'm running gdb 3.4 under 386/ix 2.0.2, which is a derivative of AT&T's
-Sys V/386 3.2.
-
-On some machines, gdb crashes when it's starting up while calling the
-vendor's termio tgetent() routine. It always works when run under
-itself (actually, under 3.2, it's not an infinitely recursive bug.)
-After some poking around, it appears that depending on the environment
-size, or whether you're running YP, or the phase of the moon or something,
-the stack is not always long-aligned when main() is called, and tgetent()
-takes strong offense at that. On some machines this bug never appears, but
-on those where it does, it occurs quite reliably. */
+ Sys V/386 3.2.
+
+ On some machines, gdb crashes when it's starting up while calling the
+ vendor's termio tgetent() routine. It always works when run under
+ itself (actually, under 3.2, it's not an infinitely recursive bug.)
+ After some poking around, it appears that depending on the environment
+ size, or whether you're running YP, or the phase of the moon or something,
+ the stack is not always long-aligned when main() is called, and tgetent()
+ takes strong offense at that. On some machines this bug never appears, but
+ on those where it does, it occurs quite reliably. */
#define ALIGN_STACK_ON_STARTUP
/* define USG if you are using sys5 /usr/include's */
@@ -42,4 +41,3 @@ on those where it does, it occurs quite reliably. */
to get the offset in the core file of the register values. */
#define KERNEL_U_ADDR 0xe0000000
-
diff --git a/contrib/gdb/gdb/config/i386/xm-i386v32.h b/contrib/gdb/gdb/config/i386/xm-i386v32.h
index daaac80..706822f 100644
--- a/contrib/gdb/gdb/config/i386/xm-i386v32.h
+++ b/contrib/gdb/gdb/config/i386/xm-i386v32.h
@@ -1,21 +1,22 @@
/* Macro defintions for i386, running System V 3.2.
Copyright (C) 1989 Free Software Foundation, Inc.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
#include "i386/xm-i386v.h"
diff --git a/contrib/gdb/gdb/config/i386/xm-i386v4.h b/contrib/gdb/gdb/config/i386/xm-i386v4.h
index 7f782db..c324110 100644
--- a/contrib/gdb/gdb/config/i386/xm-i386v4.h
+++ b/contrib/gdb/gdb/config/i386/xm-i386v4.h
@@ -1,22 +1,23 @@
/* Macro definitions for GDB on an Intel i386 running SVR4.
- Copyright 1991, 1992 Free Software Foundation, Inc.
+ Copyright 1991, 1992, 1994, 1996 Free Software Foundation, Inc.
Written by Fred Fish at Cygnus Support (fnf@cygnus.com).
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
/* Pick up most of what we need from the generic i386 host include file. */
diff --git a/contrib/gdb/gdb/config/i386/xm-nbsd.h b/contrib/gdb/gdb/config/i386/xm-nbsd.h
index b5624ac..415d0fa 100644
--- a/contrib/gdb/gdb/config/i386/xm-nbsd.h
+++ b/contrib/gdb/gdb/config/i386/xm-nbsd.h
@@ -1,21 +1,24 @@
/* Parameters for execution on a i386 running NetBSD, for GDB.
- Copyright 1994 Free Software Foundation, Inc.
+ Copyright 1994, 2000 Free Software Foundation, Inc.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
/* Get generic NetBSD host definitions. */
#include "xm-nbsd.h"
+
+#define HOST_LONG_DOUBLE_FORMAT &floatformat_i387_ext
diff --git a/contrib/gdb/gdb/config/i386/xm-ptx.h b/contrib/gdb/gdb/config/i386/xm-ptx.h
index 99b46cc..6dfb9d6 100644
--- a/contrib/gdb/gdb/config/i386/xm-ptx.h
+++ b/contrib/gdb/gdb/config/i386/xm-ptx.h
@@ -1,23 +1,24 @@
/* Definitions to make GDB run on a Sequent Symmetry under ptx, with
Weitek 1167 and i387 support.
- Copyright 1986, 1987, 1989, 1992, 1993, 1996
+ Copyright 1986, 1987, 1989, 1992, 1993, 1994, 1995
Free Software Foundation, Inc.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
/* Symmetry version by Jay Vosburgh (fubar@sequent.com) */
@@ -34,8 +35,4 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define HAVE_TERMIOS
#define USG
-#define NEED_POSIX_SETPGID
-
#define USE_O_NOCTTY
-
-#define HOST_BYTE_ORDER LITTLE_ENDIAN
diff --git a/contrib/gdb/gdb/config/i386/xm-ptx4.h b/contrib/gdb/gdb/config/i386/xm-ptx4.h
index bdbdefd..2f466e6 100644
--- a/contrib/gdb/gdb/config/i386/xm-ptx4.h
+++ b/contrib/gdb/gdb/config/i386/xm-ptx4.h
@@ -1,22 +1,24 @@
/* Definitions to make GDB run on a Sequent Symmetry under ptx, with
- Weitek 1167 and i387 support. Copyright 1986, 1987, 1989, 1992,
- 1993 Free Software Foundation, Inc.
+ Weitek 1167 and i387 support.
+ Copyright 1986, 1987, 1989, 1992, 1993, 1994
+ Free Software Foundation, Inc.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
/* Symmetry version by Jay Vosburgh (fubar@sequent.com) */
diff --git a/contrib/gdb/gdb/config/i386/xm-symmetry.h b/contrib/gdb/gdb/config/i386/xm-symmetry.h
index 52e9a9a..781a343 100644
--- a/contrib/gdb/gdb/config/i386/xm-symmetry.h
+++ b/contrib/gdb/gdb/config/i386/xm-symmetry.h
@@ -1,22 +1,24 @@
/* Definitions to make GDB run on a Sequent Symmetry under
dynix 3.1, with Weitek 1167 and i387 support.
- Copyright 1986, 1987, 1989, 1992, 1993, 1994 Free Software Foundation, Inc.
+ Copyright 1986, 1987, 1989, 1992, 1993, 1994
+ Free Software Foundation, Inc.
-This file is part of GDB.
+ 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 free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
/* Symmetry version by Jay Vosburgh (fubar@sequent.com) */
@@ -24,5 +26,3 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define NO_SIGINTERRUPT
#define HAVE_WAIT_STRUCT
-
-#define HOST_BYTE_ORDER LITTLE_ENDIAN
diff --git a/contrib/gdb/gdb/config/ia64/aix.mh b/contrib/gdb/gdb/config/ia64/aix.mh
new file mode 100644
index 0000000..e180594
--- /dev/null
+++ b/contrib/gdb/gdb/config/ia64/aix.mh
@@ -0,0 +1,8 @@
+# Host: Intel IA-64 running AIX
+
+XM_FILE= xm-aix.h
+
+NAT_FILE= nm-aix.h
+NATDEPFILES= corelow.o core-regset.o solib.o solib-aix5.o fork-child.o \
+ procfs.o proc-api.o proc-events.o proc-flags.o proc-why.o \
+ ia64-aix-nat.o
diff --git a/contrib/gdb/gdb/config/ia64/aix.mt b/contrib/gdb/gdb/config/ia64/aix.mt
new file mode 100644
index 0000000..0348146
--- /dev/null
+++ b/contrib/gdb/gdb/config/ia64/aix.mt
@@ -0,0 +1,4 @@
+# Target: Intel IA-64 running AIX
+
+TDEPFILES= ia64-tdep.o ia64-linux-tdep.o ia64-aix-tdep.o
+TM_FILE= tm-aix.h
diff --git a/contrib/gdb/gdb/config/ia64/linux.mh b/contrib/gdb/gdb/config/ia64/linux.mh
new file mode 100644
index 0000000..65f3028
--- /dev/null
+++ b/contrib/gdb/gdb/config/ia64/linux.mh
@@ -0,0 +1,10 @@
+# Host: Intel IA-64 running GNU/Linux
+
+XM_FILE= xm-linux.h
+
+NAT_FILE= nm-linux.h
+NATDEPFILES= infptrace.o inftarg.o fork-child.o corelow.o gcore.o \
+ core-aout.o core-regset.o ia64-linux-nat.o linux-proc.o \
+ proc-service.o thread-db.o lin-lwp.o
+
+LOADLIBES = -ldl -rdynamic
diff --git a/contrib/gdb/gdb/config/ia64/linux.mt b/contrib/gdb/gdb/config/ia64/linux.mt
new file mode 100644
index 0000000..d841f75
--- /dev/null
+++ b/contrib/gdb/gdb/config/ia64/linux.mt
@@ -0,0 +1,6 @@
+# Target: Intel IA-64 running GNU/Linux
+TDEPFILES= ia64-tdep.o ia64-aix-tdep.o ia64-linux-tdep.o \
+ solib.o solib-svr4.o solib-legacy.o
+TM_FILE= tm-linux.h
+
+GDBSERVER_DEPFILES = linux-low.o linux-ia64-low.o reg-ia64.o
diff --git a/contrib/gdb/gdb/config/ia64/nm-aix.h b/contrib/gdb/gdb/config/ia64/nm-aix.h
new file mode 100644
index 0000000..3f6764c
--- /dev/null
+++ b/contrib/gdb/gdb/config/ia64/nm-aix.h
@@ -0,0 +1,37 @@
+/* Native support for AIX, for GDB, the GNU debugger.
+ Copyright 2000, 2001 Free Software Foundation, Inc.
+
+ This file is part of GDB.
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
+
+#ifndef NM_AIX_H
+#define NM_AIX_H
+
+#include "nm-sysv4.h"
+
+#ifndef AIX5
+#define AIX5 1
+#endif
+
+/* Type of the operation code for sending control messages to the
+ /proc/PID/ctl file */
+#define PROC_CTL_WORD_TYPE int
+
+#define GDB_GREGSET_T prgregset_t
+#define GDB_FPREGSET_T prfpregset_t
+
+#endif /* #ifndef NM_AIX_H */
diff --git a/contrib/gdb/gdb/config/ia64/nm-linux.h b/contrib/gdb/gdb/config/ia64/nm-linux.h
new file mode 100644
index 0000000..2c980c0
--- /dev/null
+++ b/contrib/gdb/gdb/config/ia64/nm-linux.h
@@ -0,0 +1,79 @@
+/* Native support for GNU/Linux, for GDB, the GNU debugger.
+ Copyright 1999, 2000, 2001
+ Free Software Foundation, Inc.
+
+ This file is part of GDB.
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
+
+#ifndef NM_LINUX_H
+#define NM_LINUX_H
+
+#include "nm-linux.h"
+
+/* Note: It seems likely that we'll have to eventually define
+ FETCH_INFERIOR_REGISTERS. But until that time, we'll make do
+ with the following. */
+
+#define CANNOT_FETCH_REGISTER(regno) ia64_cannot_fetch_register(regno)
+extern int ia64_cannot_fetch_register (int regno);
+
+#define CANNOT_STORE_REGISTER(regno) ia64_cannot_store_register(regno)
+extern int ia64_cannot_store_register (int regno);
+
+#ifdef GDBSERVER
+#define REGISTER_U_ADDR(addr, blockend, regno) \
+ (addr) = ia64_register_u_addr ((blockend),(regno));
+
+extern int ia64_register_u_addr(int, int);
+#endif /* GDBSERVER */
+
+#define U_REGS_OFFSET 0
+
+#define PTRACE_ARG3_TYPE long
+#define PTRACE_XFER_TYPE long
+
+/* Hardware watchpoints */
+
+#define TARGET_HAS_HARDWARE_WATCHPOINTS
+
+#define TARGET_CAN_USE_HARDWARE_WATCHPOINT(type, cnt, ot) 1
+
+/* The IA-64 architecture can step over a watch point (without triggering
+ it again) if the "dd" (data debug fault disable) bit in the processor
+ status word is set.
+
+ This PSR bit is set in ia64_linux_stopped_by_watchpoint when the
+ code there has determined that a hardware watchpoint has indeed
+ been hit. The CPU will then be able to execute one instruction
+ without triggering a watchpoint. */
+#define HAVE_STEPPABLE_WATCHPOINT 1
+
+#define STOPPED_BY_WATCHPOINT(W) \
+ ia64_linux_stopped_by_watchpoint (inferior_ptid)
+extern CORE_ADDR ia64_linux_stopped_by_watchpoint (ptid_t ptid);
+
+#define target_insert_watchpoint(addr, len, type) \
+ ia64_linux_insert_watchpoint (inferior_ptid, addr, len, type)
+extern int ia64_linux_insert_watchpoint (ptid_t ptid, CORE_ADDR addr,
+ int len, int rw);
+
+#define target_remove_watchpoint(addr, len, type) \
+ ia64_linux_remove_watchpoint (inferior_ptid, addr, len)
+extern int ia64_linux_remove_watchpoint (ptid_t ptid, CORE_ADDR addr,
+ int len);
+
+#endif /* #ifndef NM_LINUX_H */
diff --git a/contrib/gdb/gdb/config/ia64/tm-aix.h b/contrib/gdb/gdb/config/ia64/tm-aix.h
new file mode 100644
index 0000000..0160140
--- /dev/null
+++ b/contrib/gdb/gdb/config/ia64/tm-aix.h
@@ -0,0 +1,32 @@
+/* Definitions to target GDB to GNU/Linux on IA-64 running AIX.
+ Copyright 2000, 2001 Free Software Foundation, Inc.
+
+ This file is part of GDB.
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
+
+#ifndef TM_AIX_H
+#define TM_AIX_H
+
+#include "ia64/tm-ia64.h"
+#include "tm-sysv4.h"
+
+#define TARGET_ELF64
+
+extern int ia64_aix_in_sigtramp (CORE_ADDR pc, char *func_name);
+#define IN_SIGTRAMP(pc,func_name) ia64_aix_in_sigtramp (pc, func_name)
+
+#endif /* #ifndef TM_AIX_H */
diff --git a/contrib/gdb/gdb/config/ia64/tm-ia64.h b/contrib/gdb/gdb/config/ia64/tm-ia64.h
new file mode 100644
index 0000000..d08e59b
--- /dev/null
+++ b/contrib/gdb/gdb/config/ia64/tm-ia64.h
@@ -0,0 +1,252 @@
+/* Definitions to target GDB to GNU/Linux on an ia64 architecture.
+ Copyright 1992, 1993, 2000 Free Software Foundation, Inc.
+
+ This file is part of GDB.
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
+
+#ifndef TM_IA64_H
+#define TM_IA64_H
+
+#if !defined(GDBSERVER)
+
+#define GDB_MULTI_ARCH 1
+
+#else /* defines needed for GDBSERVER */
+
+/* Say how long (ordinary) registers are. This is a piece of bogosity
+ used in push_word and a few other places; REGISTER_RAW_SIZE is the
+ real way to know how big a register is. */
+
+#define REGISTER_SIZE 8
+
+#undef NUM_REGS
+#define NUM_REGS 590
+
+/* Some pseudo register numbers */
+
+#define PC_REGNUM IA64_IP_REGNUM
+#define SP_REGNUM IA64_GR12_REGNUM
+#define FP_REGNUM IA64_VFP_REGNUM
+
+/* Total amount of space needed to store our copies of the machine's
+ register state, the array `registers'. On the ia64, all registers
+ fit in 64 bits except for the floating point registers which require
+ 84 bits. But 84 isn't a nice number, so we'll just allocate 128
+ bits for each of these. The expression below says that we
+ 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)
+
+/* Index within `registers' of the first byte of the space for
+ register N. */
+
+#define REGISTER_BYTE(N) (((N) * 8) \
+ + ((N) <= IA64_FR0_REGNUM ? 0 : 8 * (((N) > IA64_FR127_REGNUM) ? 128 : (N) - IA64_FR0_REGNUM)))
+
+/* Number of bytes of storage in the actual machine representation
+ for register N. */
+
+#define REGISTER_RAW_SIZE(N) \
+ ((IA64_FR0_REGNUM <= (N) && (N) <= IA64_FR127_REGNUM) ? 16 : 8)
+
+/* Largest value REGISTER_RAW_SIZE can have. */
+
+#define MAX_REGISTER_RAW_SIZE 16
+
+
+#define GDBSERVER_RESUME_REGS { IA64_IP_REGNUM, IA64_PSR_REGNUM, SP_REGNUM, IA64_BSP_REGNUM, IA64_CFM_REGNUM }
+
+#endif /* GDBSERVER */
+
+
+/* Register numbers of various important registers */
+
+/* General registers; there are 128 of these 64 bit wide registers. The
+ first 32 are static and the last 96 are stacked. */
+#define IA64_GR0_REGNUM 0
+#define IA64_GR1_REGNUM (IA64_GR0_REGNUM+1)
+#define IA64_GR2_REGNUM (IA64_GR0_REGNUM+2)
+#define IA64_GR3_REGNUM (IA64_GR0_REGNUM+3)
+#define IA64_GR4_REGNUM (IA64_GR0_REGNUM+4)
+#define IA64_GR5_REGNUM (IA64_GR0_REGNUM+5)
+#define IA64_GR6_REGNUM (IA64_GR0_REGNUM+6)
+#define IA64_GR7_REGNUM (IA64_GR0_REGNUM+7)
+#define IA64_GR8_REGNUM (IA64_GR0_REGNUM+8)
+#define IA64_GR9_REGNUM (IA64_GR0_REGNUM+9)
+#define IA64_GR10_REGNUM (IA64_GR0_REGNUM+10)
+#define IA64_GR11_REGNUM (IA64_GR0_REGNUM+11)
+#define IA64_GR12_REGNUM (IA64_GR0_REGNUM+12)
+#define IA64_GR31_REGNUM (IA64_GR0_REGNUM+31)
+#define IA64_GR32_REGNUM (IA64_GR0_REGNUM+32)
+#define IA64_GR127_REGNUM (IA64_GR0_REGNUM+127)
+
+/* Floating point registers; 128 82-bit wide registers */
+#define IA64_FR0_REGNUM 128
+#define IA64_FR1_REGNUM (IA64_FR0_REGNUM+1)
+#define IA64_FR2_REGNUM (IA64_FR0_REGNUM+2)
+#define IA64_FR8_REGNUM (IA64_FR0_REGNUM+8)
+#define IA64_FR9_REGNUM (IA64_FR0_REGNUM+9)
+#define IA64_FR10_REGNUM (IA64_FR0_REGNUM+10)
+#define IA64_FR11_REGNUM (IA64_FR0_REGNUM+11)
+#define IA64_FR12_REGNUM (IA64_FR0_REGNUM+12)
+#define IA64_FR13_REGNUM (IA64_FR0_REGNUM+13)
+#define IA64_FR14_REGNUM (IA64_FR0_REGNUM+14)
+#define IA64_FR15_REGNUM (IA64_FR0_REGNUM+15)
+#define IA64_FR16_REGNUM (IA64_FR0_REGNUM+16)
+#define IA64_FR31_REGNUM (IA64_FR0_REGNUM+31)
+#define IA64_FR32_REGNUM (IA64_FR0_REGNUM+32)
+#define IA64_FR127_REGNUM (IA64_FR0_REGNUM+127)
+
+/* Predicate registers; There are 64 of these one bit registers.
+ It'd be more convenient (implementation-wise) to use a single
+ 64 bit word with all of these register in them. Note that there's
+ also a IA64_PR_REGNUM below which contains all the bits and is used for
+ communicating the actual values to the target. */
+
+#define IA64_PR0_REGNUM 256
+#define IA64_PR1_REGNUM (IA64_PR0_REGNUM+1)
+#define IA64_PR2_REGNUM (IA64_PR0_REGNUM+2)
+#define IA64_PR3_REGNUM (IA64_PR0_REGNUM+3)
+#define IA64_PR4_REGNUM (IA64_PR0_REGNUM+4)
+#define IA64_PR5_REGNUM (IA64_PR0_REGNUM+5)
+#define IA64_PR6_REGNUM (IA64_PR0_REGNUM+6)
+#define IA64_PR7_REGNUM (IA64_PR0_REGNUM+7)
+#define IA64_PR8_REGNUM (IA64_PR0_REGNUM+8)
+#define IA64_PR9_REGNUM (IA64_PR0_REGNUM+9)
+#define IA64_PR10_REGNUM (IA64_PR0_REGNUM+10)
+#define IA64_PR11_REGNUM (IA64_PR0_REGNUM+11)
+#define IA64_PR12_REGNUM (IA64_PR0_REGNUM+12)
+#define IA64_PR13_REGNUM (IA64_PR0_REGNUM+13)
+#define IA64_PR14_REGNUM (IA64_PR0_REGNUM+14)
+#define IA64_PR15_REGNUM (IA64_PR0_REGNUM+15)
+#define IA64_PR16_REGNUM (IA64_PR0_REGNUM+16)
+#define IA64_PR17_REGNUM (IA64_PR0_REGNUM+17)
+#define IA64_PR18_REGNUM (IA64_PR0_REGNUM+18)
+#define IA64_PR19_REGNUM (IA64_PR0_REGNUM+19)
+#define IA64_PR20_REGNUM (IA64_PR0_REGNUM+20)
+#define IA64_PR21_REGNUM (IA64_PR0_REGNUM+21)
+#define IA64_PR22_REGNUM (IA64_PR0_REGNUM+22)
+#define IA64_PR23_REGNUM (IA64_PR0_REGNUM+23)
+#define IA64_PR24_REGNUM (IA64_PR0_REGNUM+24)
+#define IA64_PR25_REGNUM (IA64_PR0_REGNUM+25)
+#define IA64_PR26_REGNUM (IA64_PR0_REGNUM+26)
+#define IA64_PR27_REGNUM (IA64_PR0_REGNUM+27)
+#define IA64_PR28_REGNUM (IA64_PR0_REGNUM+28)
+#define IA64_PR29_REGNUM (IA64_PR0_REGNUM+29)
+#define IA64_PR30_REGNUM (IA64_PR0_REGNUM+30)
+#define IA64_PR31_REGNUM (IA64_PR0_REGNUM+31)
+#define IA64_PR32_REGNUM (IA64_PR0_REGNUM+32)
+#define IA64_PR33_REGNUM (IA64_PR0_REGNUM+33)
+#define IA64_PR34_REGNUM (IA64_PR0_REGNUM+34)
+#define IA64_PR35_REGNUM (IA64_PR0_REGNUM+35)
+#define IA64_PR36_REGNUM (IA64_PR0_REGNUM+36)
+#define IA64_PR37_REGNUM (IA64_PR0_REGNUM+37)
+#define IA64_PR38_REGNUM (IA64_PR0_REGNUM+38)
+#define IA64_PR39_REGNUM (IA64_PR0_REGNUM+39)
+#define IA64_PR40_REGNUM (IA64_PR0_REGNUM+40)
+#define IA64_PR41_REGNUM (IA64_PR0_REGNUM+41)
+#define IA64_PR42_REGNUM (IA64_PR0_REGNUM+42)
+#define IA64_PR43_REGNUM (IA64_PR0_REGNUM+43)
+#define IA64_PR44_REGNUM (IA64_PR0_REGNUM+44)
+#define IA64_PR45_REGNUM (IA64_PR0_REGNUM+45)
+#define IA64_PR46_REGNUM (IA64_PR0_REGNUM+46)
+#define IA64_PR47_REGNUM (IA64_PR0_REGNUM+47)
+#define IA64_PR48_REGNUM (IA64_PR0_REGNUM+48)
+#define IA64_PR49_REGNUM (IA64_PR0_REGNUM+49)
+#define IA64_PR50_REGNUM (IA64_PR0_REGNUM+50)
+#define IA64_PR51_REGNUM (IA64_PR0_REGNUM+51)
+#define IA64_PR52_REGNUM (IA64_PR0_REGNUM+52)
+#define IA64_PR53_REGNUM (IA64_PR0_REGNUM+53)
+#define IA64_PR54_REGNUM (IA64_PR0_REGNUM+54)
+#define IA64_PR55_REGNUM (IA64_PR0_REGNUM+55)
+#define IA64_PR56_REGNUM (IA64_PR0_REGNUM+56)
+#define IA64_PR57_REGNUM (IA64_PR0_REGNUM+57)
+#define IA64_PR58_REGNUM (IA64_PR0_REGNUM+58)
+#define IA64_PR59_REGNUM (IA64_PR0_REGNUM+59)
+#define IA64_PR60_REGNUM (IA64_PR0_REGNUM+60)
+#define IA64_PR61_REGNUM (IA64_PR0_REGNUM+61)
+#define IA64_PR62_REGNUM (IA64_PR0_REGNUM+62)
+#define IA64_PR63_REGNUM (IA64_PR0_REGNUM+63)
+
+
+/* Branch registers: 8 64-bit registers for holding branch targets */
+#define IA64_BR0_REGNUM 320
+#define IA64_BR1_REGNUM (IA64_BR0_REGNUM+1)
+#define IA64_BR2_REGNUM (IA64_BR0_REGNUM+2)
+#define IA64_BR3_REGNUM (IA64_BR0_REGNUM+3)
+#define IA64_BR4_REGNUM (IA64_BR0_REGNUM+4)
+#define IA64_BR5_REGNUM (IA64_BR0_REGNUM+5)
+#define IA64_BR6_REGNUM (IA64_BR0_REGNUM+6)
+#define IA64_BR7_REGNUM (IA64_BR0_REGNUM+7)
+
+/* Virtual frame pointer; this matches IA64_FRAME_POINTER_REGNUM in
+ gcc/config/ia64/ia64.h. */
+#define IA64_VFP_REGNUM 328
+
+/* Virtual return address pointer; this matches IA64_RETURN_ADDRESS_POINTER_REGNUM
+ in gcc/config/ia64/ia64.h. */
+#define IA64_VRAP_REGNUM 329
+
+/* Predicate registers: There are 64 of these 1-bit registers. We
+ define a single register which is used to communicate these values
+ to/from the target. We will somehow contrive to make it appear that
+ IA64_PR0_REGNUM thru IA64_PR63_REGNUM hold the actual values. */
+#define IA64_PR_REGNUM 330
+
+/* Instruction pointer: 64 bits wide */
+#define IA64_IP_REGNUM 331
+
+/* Process Status Register */
+#define IA64_PSR_REGNUM 332
+
+/* Current Frame Marker (Raw form may be the cr.ifs) */
+#define IA64_CFM_REGNUM 333
+
+/* Application registers; 128 64-bit wide registers possible, but some
+ of them are reserved */
+#define IA64_AR0_REGNUM 334
+#define IA64_KR0_REGNUM (IA64_AR0_REGNUM+0)
+#define IA64_KR7_REGNUM (IA64_KR0_REGNUM+7)
+
+#define IA64_RSC_REGNUM (IA64_AR0_REGNUM+16)
+#define IA64_BSP_REGNUM (IA64_AR0_REGNUM+17)
+#define IA64_BSPSTORE_REGNUM (IA64_AR0_REGNUM+18)
+#define IA64_RNAT_REGNUM (IA64_AR0_REGNUM+19)
+#define IA64_FCR_REGNUM (IA64_AR0_REGNUM+21)
+#define IA64_EFLAG_REGNUM (IA64_AR0_REGNUM+24)
+#define IA64_CSD_REGNUM (IA64_AR0_REGNUM+25)
+#define IA64_SSD_REGNUM (IA64_AR0_REGNUM+26)
+#define IA64_CFLG_REGNUM (IA64_AR0_REGNUM+27)
+#define IA64_FSR_REGNUM (IA64_AR0_REGNUM+28)
+#define IA64_FIR_REGNUM (IA64_AR0_REGNUM+29)
+#define IA64_FDR_REGNUM (IA64_AR0_REGNUM+30)
+#define IA64_CCV_REGNUM (IA64_AR0_REGNUM+32)
+#define IA64_UNAT_REGNUM (IA64_AR0_REGNUM+36)
+#define IA64_FPSR_REGNUM (IA64_AR0_REGNUM+40)
+#define IA64_ITC_REGNUM (IA64_AR0_REGNUM+44)
+#define IA64_PFS_REGNUM (IA64_AR0_REGNUM+64)
+#define IA64_LC_REGNUM (IA64_AR0_REGNUM+65)
+#define IA64_EC_REGNUM (IA64_AR0_REGNUM+66)
+
+/* NAT (Not A Thing) Bits for the general registers; there are 128 of these */
+#define IA64_NAT0_REGNUM 462
+#define IA64_NAT31_REGNUM (IA64_NAT0_REGNUM+31)
+#define IA64_NAT32_REGNUM (IA64_NAT0_REGNUM+32)
+#define IA64_NAT127_REGNUM (IA64_NAT0_REGNUM+127)
+
+#endif /* TM_IA64_H */
diff --git a/contrib/gdb/gdb/config/ia64/tm-linux.h b/contrib/gdb/gdb/config/ia64/tm-linux.h
new file mode 100644
index 0000000..f716d83
--- /dev/null
+++ b/contrib/gdb/gdb/config/ia64/tm-linux.h
@@ -0,0 +1,34 @@
+/* Definitions to target GDB to GNU/Linux on IA-64 Linux.
+ Copyright 1992, 1993, 2000 Free Software Foundation, Inc.
+
+ This file is part of GDB.
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
+
+#ifndef TM_LINUX_H
+#define TM_LINUX_H
+
+#define IA64_GNULINUX_TARGET
+
+#include "ia64/tm-ia64.h"
+#include "tm-linux.h"
+
+#define TARGET_ELF64
+
+extern int ia64_linux_in_sigtramp (CORE_ADDR pc, char *func_name);
+#define IN_SIGTRAMP(pc,func_name) ia64_linux_in_sigtramp (pc, func_name)
+
+#endif /* #ifndef TM_LINUX_H */
diff --git a/contrib/gdb/gdb/config/ia64/xm-aix.h b/contrib/gdb/gdb/config/ia64/xm-aix.h
new file mode 100644
index 0000000..6ca026d
--- /dev/null
+++ b/contrib/gdb/gdb/config/ia64/xm-aix.h
@@ -0,0 +1,28 @@
+/* Native support for AIX, for GDB, the GNU debugger.
+ Copyright 2000, 2001 Free Software Foundation, Inc.
+
+ This file is part of GDB.
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
+
+#ifndef XM_AIX_H
+#define XM_AIX_H
+
+/* Pick up more stuff from the generic SVR4 host include file. */
+
+#include "xm-sysv4.h"
+
+#endif /* #ifndef XM_AIX_H */
diff --git a/contrib/gdb/gdb/config/ia64/xm-linux.h b/contrib/gdb/gdb/config/ia64/xm-linux.h
new file mode 100644
index 0000000..adf6b21
--- /dev/null
+++ b/contrib/gdb/gdb/config/ia64/xm-linux.h
@@ -0,0 +1,28 @@
+/* Native support for GNU/Linux, for GDB, the GNU debugger.
+ Copyright 1999, 2000, 2001 Free Software Foundation, Inc.
+
+ This file is part of GDB.
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
+
+#ifndef XM_LINUX_H
+#define XM_LINUX_H
+
+/* This is the amount to subtract from u.u_ar0
+ to get the offset in the core file of the register values. */
+#define KERNEL_U_ADDR 0x0
+
+#endif /* #ifndef XM_LINUX_H */
diff --git a/contrib/gdb/gdb/config/nm-linux.h b/contrib/gdb/gdb/config/nm-linux.h
new file mode 100644
index 0000000..a2d4292
--- /dev/null
+++ b/contrib/gdb/gdb/config/nm-linux.h
@@ -0,0 +1,74 @@
+/* Native support for GNU/Linux.
+
+ Copyright 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
+
+ This file is part of GDB.
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
+
+/* GNU/Linux is SVR4-ish but its /proc file system isn't. */
+#undef USE_PROC_FS
+
+/* Tell GDB that we can attach and detach other processes. */
+#define ATTACH_DETACH
+
+/* Since we're building a native debugger, we can include <signal.h>
+ to find the range of real-time signals. */
+
+#include <signal.h>
+
+#ifdef __SIGRTMIN
+#define REALTIME_LO __SIGRTMIN
+#define REALTIME_HI (__SIGRTMAX + 1)
+#endif
+
+/* We define this if link.h is available, because with ELF we use SVR4
+ style shared libraries. */
+
+#ifdef HAVE_LINK_H
+#define SVR4_SHARED_LIBS
+#include "solib.h" /* Support for shared libraries. */
+#endif
+
+
+/* Override child_wait in `inftarg.c'. */
+struct target_waitstatus;
+extern ptid_t child_wait (ptid_t ptid, struct target_waitstatus *ourstatus);
+#define CHILD_WAIT
+
+extern int lin_lwp_prepare_to_proceed (void);
+#define PREPARE_TO_PROCEED(select_it) lin_lwp_prepare_to_proceed ()
+
+extern void lin_lwp_attach_lwp (ptid_t ptid, int verbose);
+#define ATTACH_LWP(ptid, verbose) lin_lwp_attach_lwp ((ptid), (verbose))
+
+extern void lin_thread_get_thread_signals (sigset_t *mask);
+#define GET_THREAD_SIGNALS(mask) lin_thread_get_thread_signals (mask)
+
+/* Defined to make stepping-over-breakpoints be thread-atomic. */
+#define USE_THREAD_STEP_NEEDED 1
+
+
+/* Use elf_gregset_t and elf_fpregset_t, rather than
+ gregset_t and fpregset_t. */
+
+#define GDB_GREGSET_T elf_gregset_t
+#define GDB_FPREGSET_T elf_fpregset_t
+
+/* Override child_pid_to_exec_file in 'inftarg.c'. */
+#define CHILD_PID_TO_EXEC_FILE
+
+
diff --git a/contrib/gdb/gdb/config/none/nm-none.h b/contrib/gdb/gdb/config/none/nm-none.h
new file mode 100644
index 0000000..7647bdb
--- /dev/null
+++ b/contrib/gdb/gdb/config/none/nm-none.h
@@ -0,0 +1,19 @@
+/* Defines needed when configuring for "none".
+ Copyright 1993 Free Software Foundation, Inc.
+
+ This file is part of GDB.
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
diff --git a/contrib/gdb/gdb/config/none/none.mh b/contrib/gdb/gdb/config/none/none.mh
new file mode 100644
index 0000000..33d5e4a
--- /dev/null
+++ b/contrib/gdb/gdb/config/none/none.mh
@@ -0,0 +1,5 @@
+# Host: "no target". This can be used to build you
+# a Makefile that only runs administrative commands like 'clean',
+# 'gdb.tar.Z', etc.
+NAT_FILE= nm-none.h
+XM_FILE= xm-none.h
diff --git a/contrib/gdb/gdb/config/none/none.mt b/contrib/gdb/gdb/config/none/none.mt
new file mode 100644
index 0000000..300e2dc
--- /dev/null
+++ b/contrib/gdb/gdb/config/none/none.mt
@@ -0,0 +1,4 @@
+# Target: "no target".
+# This can be used to build you a Makefile that only runs administrative
+# commands like 'clean', 'gdb.tar.Z', etc.
+TM_FILE= tm-none.h
diff --git a/contrib/gdb/gdb/config/none/tm-none.h b/contrib/gdb/gdb/config/none/tm-none.h
new file mode 100644
index 0000000..3db049a
--- /dev/null
+++ b/contrib/gdb/gdb/config/none/tm-none.h
@@ -0,0 +1,24 @@
+/* Defines needed when configuring for "none".
+ Copyright 1993, 1998 Free Software Foundation, Inc.
+
+ This file is part of GDB.
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
+
+/* This define is needed so that "gcc -MM" doesn't get errors and fail on
+ source files that use the value of INNER_THAN in preprocessor lines. */
+
+#define INNER_THAN(lhs,rhs) ((lhs) < (rhs))
diff --git a/contrib/gdb/gdb/config/none/xm-none.h b/contrib/gdb/gdb/config/none/xm-none.h
new file mode 100644
index 0000000..7647bdb
--- /dev/null
+++ b/contrib/gdb/gdb/config/none/xm-none.h
@@ -0,0 +1,19 @@
+/* Defines needed when configuring for "none".
+ Copyright 1993 Free Software Foundation, Inc.
+
+ This file is part of GDB.
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
diff --git a/contrib/gdb/gdb/config/tm-linux.h b/contrib/gdb/gdb/config/tm-linux.h
new file mode 100644
index 0000000..9389872
--- /dev/null
+++ b/contrib/gdb/gdb/config/tm-linux.h
@@ -0,0 +1,42 @@
+/* Native support for GNU/Linux, for GDB, the GNU debugger.
+ Copyright 1999, 2000
+ Free Software Foundation, Inc.
+
+ This file is part of GDB.
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
+
+/* Pick reasonable defaults for the number of real-time signals. */
+
+#ifndef REALTIME_LO
+#define REALTIME_LO 32
+#endif
+#ifndef REALTIME_HI
+#define REALTIME_HI 64
+#endif
+
+/* We need this file for the SOLIB_TRAMPOLINE stuff. */
+
+#include "tm-sysv4.h"
+
+/* We define SVR4_SHARED_LIBS unconditionally, on the assumption that
+ link.h is available on all linux platforms. For I386 and SH3/4,
+ we hard-code the information rather than use link.h anyway (for
+ the benefit of cross-debugging). We may move to doing that for
+ other architectures as well. */
+
+#define SVR4_SHARED_LIBS
+#include "solib.h" /* Support for shared libraries. */
diff --git a/contrib/gdb/gdb/config/tm-vxworks.h b/contrib/gdb/gdb/config/tm-vxworks.h
new file mode 100644
index 0000000..9afc0b4
--- /dev/null
+++ b/contrib/gdb/gdb/config/tm-vxworks.h
@@ -0,0 +1,23 @@
+/* Target machine description for VxWorks, for GDB, the GNU debugger.
+ Copyright 1999 Free Software Foundation, Inc.
+
+ This file is part of GDB.
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
+
+#define GDBINIT_FILENAME ".vxgdbinit"
+
+#define DEFAULT_PROMPT "(vxgdb) "
OpenPOWER on IntegriCloud