+Wed Aug 21 18:21:09 1991 John Gilmore (gnu at cygint.cygnus.com)
+
+ * infptrace.c (KERNEL_U_ADDR_BSD): Include a.out.gnu.h.
+ * i960-tdep.c, m68k-tdep.c, sparc-tdep.c, tm-i960.h,
+ tm-m68k.h, remote-nindy.c: Change ext_format_XXX structs
+ to single structures rather than arrays; when passing
+ their address, use &. This avoids trouble with bdead compilers.
+ * mcheck.c: Don't include <stdlib.h>; just declare "void abort();"
+ instead. This avoids portability headaches.
+ * mips-tdep.c (mips_do_registers_info): Only print FP regs if
+ asked to.
+ * source.c (open_source_file): Avoid ANSI const bdeath by
+ skipping declaration and then casting result value.
+ * tm-hp300bsd.h: Clarify comment.
+ * utils.c (strstr): Result is const char *; ANSI bdeath.
+ * xm-hp300bsd.h: Define HOST_BYTE_ORDER. Redefine INT_MIN,
+ since system include file defines it differently from "defs.h",
+ though the two are equivalent for our purposes.
+
Tue Aug 20 16:01:11 1991 John Gilmore (gnu at cygint.cygnus.com)
* tconfig/sun*4: Remove warnings about system assembler.
/* Structure of i960 extended floating point format. */
-const struct ext_format ext_format_i960 [] = {
+const struct ext_format ext_format_i960 = {
/* tot sbyte smask expbyte manbyte */
- { 12, 9, 0x80, 9,8, 4,0 }, /* i960 */
+ 12, 9, 0x80, 9,8, 4,0, /* i960 */
};
/* gdb960 is always running on a non-960 host. Check its characteristics.
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */
#include "ansidecl.h"
-#include <stdlib.h>
#include "gmalloc.h"
/* Old hook values. */
static PTR EXFUN((*old_malloc_hook), (size_t size));
static PTR EXFUN((*old_realloc_hook), (PTR ptr, size_t size));
-/* FIXME. We cannot *declare* abort() as either being void or being
- int, because if the system declares it as the other, we get a fatal
- error. It's senseless to configure the system for whether abort is
- void or int. So we simply fail to declare it, which works on all
- systems, but might produce a warning on yours. Please ignore the warning
- and raise your middle finger in the general direction of the ANSI C
- committee in tribute. */
+
/* Function to call when something awful happens. */
+extern void abort();
static void EXFUN((*abortfunc), (void)) = (void (*)()) abort;
/* Arbitrary magical numbers. */
extern struct target_ops nindy_ops;
extern jmp_buf to_top_level;
extern FILE *instream;
-extern struct ext_format ext_format_i960[]; /* i960-tdep.c */
+extern struct ext_format ext_format_i960; /* i960-tdep.c */
extern char ninStopWhy ();
&nindy_regs.fp_as_double[8 * (regnum - FP0_REGNUM)],
&inv);
/* dub now in host byte order */
- double_to_ieee_extended (ext_format_i960, &dub,
+ double_to_ieee_extended (&ext_format_i960, &dub,
®isters[REGISTER_BYTE (regnum)]);
}
bcopy (®isters[REGISTER_BYTE (TCW_REGNUM)], nindy_regs.tcw, 1*4);
/* Float regs. Only works on IEEE_FLOAT hosts. */
for (regnum = FP0_REGNUM; regnum < FP0_REGNUM + 4; regnum++) {
- ieee_extended_to_double (ext_format_i960,
+ ieee_extended_to_double (&ext_format_i960,
®isters[REGISTER_BYTE (regnum)], &dub);
/* dub now in host byte order */
/* FIXME-someday, the arguments to unpack_double are backward.
/* Put the declaration out here because if it's in the macros, PCC
will complain. */
-extern struct ext_format ext_format_68881 [];
+extern struct ext_format ext_format_68881;
/* Convert data from raw format for register REGNUM
to virtual format for register REGNUM. */
#define REGISTER_CONVERT_TO_VIRTUAL(REGNUM,FROM,TO) \
{ \
if ((REGNUM) >= FP0_REGNUM && (REGNUM) < FPC_REGNUM) \
- ieee_extended_to_double (ext_format_68881, (FROM), (TO)); \
+ ieee_extended_to_double (&ext_format_68881, (FROM), (double *)(TO)); \
else \
bcopy ((FROM), (TO), 4); \
}
#define REGISTER_CONVERT_TO_RAW(REGNUM,FROM,TO) \
{ \
if ((REGNUM) >= FP0_REGNUM && (REGNUM) < FPC_REGNUM) \
- double_to_ieee_extended (ext_format_68881, (FROM), (TO)); \
+ double_to_ieee_extended (&ext_format_68881, (double *)(FROM), (TO)); \
else \
bcopy ((FROM), (TO), 4); \
}
-/* Parameters for execution on a Hewlett-Packard 9000/300, running bsd.
- Copyright (C) 1986, 1987, 1989 Free Software Foundation, Inc.
+/* Parameters for target machine Hewlett-Packard 9000/300, running bsd.
+ Copyright (C) 1986, 1987, 1989, 1991 Free Software Foundation, Inc.
This file is part of GDB.
#define REGISTER_CONVERT_TO_VIRTUAL(REGNUM,FROM,TO) \
{ \
- extern struct ext_format ext_format_i960[]; \
+ 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[]; \
+ 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); \
}
-/* Parameters for execution on a Hewlett-Packard 9000/300, running bsd.
- Copyright (C) 1986, 1987, 1989 Free Software Foundation, Inc.
+/* Parameters for hosting on a Hewlett-Packard 9000/300, running bsd.
+ Copyright (C) 1986, 1987, 1989, 1991 Free Software Foundation, Inc.
This file is part of GDB.
* Problems to hpbsd-bugs@cs.utah.edu
*/
-#include <machine/endian.h>
+#define HOST_BYTE_ORDER BIG_ENDIAN
+
+/* Avoid "INT_MIN redefined" warnings -- by defining it here, exactly
+ the same as in the system <machine/machtypes.h> file. */
+#undef INT_MIN
+#define INT_MIN 0x80000000
/* Get rid of any system-imposed stack limit if possible. */