Contributed by Intel Corporation.
This file is part of GDB.
-GDB is free software; you can redistribute it and/or modify
+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 1, or (at your option)
-any later version.
+the Free Software Foundation; either version 2 of the License, or
+(at your option) any later version.
-GDB is distributed in the hope that it will be useful,
+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 GDB; see the file COPYING. If not, write to
-the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */
+along with this program; if not, write to the Free Software
+Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */
/* Definitions to target GDB to any i960. */
/* 8 */ "r8", "r9", "r10", "r11", "r12", "r13", "r14", "r15",\
/* 16 */ "g0", "g1", "g2", "g3", "g4", "g5", "g6", "g7", \
/* 24 */ "g8", "g9", "g10", "g11", "g12", "g13", "g14", "fp", \
- /* 32 */ "pc", "ac", "ip", "tc", "fp0", "fp1", "fp2", "fp3", \
+ /* 32 */ "pcw", "ac", "tc", "ip", "fp0", "fp1", "fp2", "fp3",\
}
/* Register numbers of various important registers (used to index
#define FP_REGNUM 31 /* Contains address of executing stack frame */
#define PCW_REGNUM 32 /* process control word */
#define ACW_REGNUM 33 /* arithmetic control word */
-#define IP_REGNUM 34 /* instruction pointer */
-#define TCW_REGNUM 35 /* trace control word */
+#define TCW_REGNUM 34 /* trace control word */
+#define IP_REGNUM 35 /* instruction pointer */
#define FP0_REGNUM 36 /* First floating point register */
/* Some registers have more than one name */
/* Convert data from raw format for register REGNUM
to virtual format for register REGNUM. */
+extern struct ext_format ext_format_i960;
+
#define REGISTER_CONVERT_TO_VIRTUAL(REGNUM,FROM,TO) \
{ \
- extern struct ext_format ext_format_i960[]; \
- \
if ((REGNUM) >= FP0_REGNUM) \
- ieee_extended_to_double (ext_format_i960, (FROM), (TO)); \
+ ieee_extended_to_double (&ext_format_i960, (FROM), (double *)(TO)); \
else \
bcopy ((FROM), (TO), 4); \
}
#define REGISTER_CONVERT_TO_RAW(REGNUM,FROM,TO) \
{ \
- extern struct ext_format ext_format_i960[]; \
- \
if ((REGNUM) >= FP0_REGNUM) \
- double_to_ieee_extended (ext_format_i960, (FROM), (TO)); \
+ double_to_ieee_extended (&ext_format_i960, (double *)(FROM), (TO)); \
else \
bcopy ((FROM), (TO), 4); \
}
/* FRAME_CHAIN takes a frame's nominal address
and produces the frame's chain-pointer.
- FRAME_CHAIN_COMBINE takes the chain pointer and the frame's nominal address
- and produces the nominal address of the caller frame.
-
However, if FRAME_CHAIN_VALID returns zero,
- it means the given frame is the outermost one and has no caller.
- In that case, FRAME_CHAIN_COMBINE is not used. */
+ it means the given frame is the outermost one and has no caller. */
/* We cache information about saved registers in the frame structure,
to save us from having to re-scan function prologues every time
Set the arg_pointer to -1, which is not valid; 0 and other values
indicate real, cached values. */
-#define INIT_EXTRA_FRAME_INFO(fi) ((fi)->fsr = 0, (fi)->arg_pointer = -1)
+#define INIT_EXTRA_FRAME_INFO(fromleaf, fi) \
+ ((fi)->fsr = 0, (fi)->arg_pointer = -1)
/* On the i960, we get the chain pointer by reading the PFP saved
on the stack and clearing the status bits. */
#define FRAME_CHAIN(thisframe) \
(read_memory_integer (FRAME_FP(thisframe), 4) & ~0xf)
-#define FRAME_CHAIN_COMBINE(chain, thisframe) (chain)
-
/* FRAME_CHAIN_VALID returns zero if the given frame is the outermost one
- and has no caller. In that case, FRAME_CHAIN_COMBINE is not used.
+ and has no caller.
On the i960, each various target system type must define FRAME_CHAIN_VALID,
since it differs between NINDY and VxWorks, the two currently supported