diff options
-rw-r--r-- | gdb/ChangeLog | 13 | ||||
-rw-r--r-- | gdb/arch-utils.c | 14 | ||||
-rw-r--r-- | gdb/config/alpha/tm-alpha.h | 2 | ||||
-rw-r--r-- | gdb/config/arm/tm-arm.h | 2 | ||||
-rw-r--r-- | gdb/config/i386/tm-i386.h | 2 | ||||
-rw-r--r-- | gdb/config/i960/tm-i960.h | 2 | ||||
-rw-r--r-- | gdb/config/ia64/tm-ia64.h | 2 | ||||
-rw-r--r-- | gdb/config/mcore/tm-mcore.h | 2 | ||||
-rw-r--r-- | gdb/config/mips/tm-wince.h | 2 | ||||
-rw-r--r-- | gdb/config/mn10200/tm-mn10200.h | 2 | ||||
-rw-r--r-- | gdb/config/ns32k/tm-umax.h | 2 | ||||
-rw-r--r-- | gdb/config/powerpc/tm-ppcle-eabi.h | 2 | ||||
-rw-r--r-- | gdb/config/sh/tm-wince.h | 2 | ||||
-rw-r--r-- | gdb/config/v850/tm-v850.h | 2 | ||||
-rw-r--r-- | gdb/config/vax/tm-vax.h | 2 | ||||
-rw-r--r-- | gdb/cris-tdep.c | 2 | ||||
-rw-r--r-- | gdb/d10v-tdep.c | 2 | ||||
-rw-r--r-- | gdb/defs.h | 6 | ||||
-rw-r--r-- | gdb/doc/ChangeLog | 5 | ||||
-rw-r--r-- | gdb/doc/gdbint.texinfo | 6 | ||||
-rw-r--r-- | gdb/gdbarch.c | 5 | ||||
-rwxr-xr-x | gdb/gdbarch.sh | 4 | ||||
-rw-r--r-- | gdb/remote-rdp.c | 2 | ||||
-rw-r--r-- | gdb/remote-sim.c | 2 | ||||
-rw-r--r-- | gdb/sh-tdep.c | 4 | ||||
-rw-r--r-- | gdb/sparc-tdep.c | 4 |
26 files changed, 55 insertions, 40 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog index a4d5b179ee7..1bf5860ad5e 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,5 +1,18 @@ 2001-12-15 Andrew Cagney <ac131313@redhat.com> + * defs.h (LITTLE_ENDIAN): Delete definition. + * arch-utils.c, cris-tdep.c, d10v-tdep.c, defs.h, gdbarch.c, + gdbarch.sh, remote-rdp.c, remote-sim.c, sh-tdep.c, sparc-tdep.c, + config/alpha/tm-alpha.h, config/arm/tm-arm.h, + config/i386/tm-i386.h, config/i960/tm-i960.h, + config/ia64/tm-ia64.h, config/mcore/tm-mcore.h, + config/mips/tm-wince.h, config/mn10200/tm-mn10200.h, + config/ns32k/tm-umax.h, config/powerpc/tm-ppcle-eabi.h, + config/sh/tm-wince.h, config/v850/tm-v850.h, config/vax/tm-vax.h, + doc/gdbint.texinfo: Replace LITTLE_ENDIAN with BFD_ENDIAN_LITTLE. + +2001-12-15 Andrew Cagney <ac131313@redhat.com> + * ui-out.c (struct ui_out_table): Add field entry_level. (verify_field): New function. (verify_field_proper_position): Delete function. diff --git a/gdb/arch-utils.c b/gdb/arch-utils.c index d01ab690300..d7e82d7529c 100644 --- a/gdb/arch-utils.c +++ b/gdb/arch-utils.c @@ -195,7 +195,7 @@ default_float_format (struct gdbarch *gdbarch) { case BIG_ENDIAN: return &floatformat_ieee_single_big; - case LITTLE_ENDIAN: + case BFD_ENDIAN_LITTLE: return &floatformat_ieee_single_little; default: internal_error (__FILE__, __LINE__, @@ -216,7 +216,7 @@ default_double_format (struct gdbarch *gdbarch) { case BIG_ENDIAN: return &floatformat_ieee_double_big; - case LITTLE_ENDIAN: + case BFD_ENDIAN_LITTLE: return &floatformat_ieee_double_little; default: internal_error (__FILE__, __LINE__, @@ -467,7 +467,7 @@ set_endian (char *ignore_args, int from_tty, struct cmd_list_element *c) { struct gdbarch_info info; memset (&info, 0, sizeof info); - info.byte_order = LITTLE_ENDIAN; + info.byte_order = BFD_ENDIAN_LITTLE; if (! gdbarch_update_p (info)) { printf_unfiltered ("Little endian target not supported by GDB\n"); @@ -475,7 +475,7 @@ set_endian (char *ignore_args, int from_tty, struct cmd_list_element *c) } else { - target_byte_order = LITTLE_ENDIAN; + target_byte_order = BFD_ENDIAN_LITTLE; } } else if (set_endian_string == endian_big) @@ -517,7 +517,7 @@ set_endian_from_file (bfd *abfd) if (bfd_big_endian (abfd)) want = BIG_ENDIAN; else - want = LITTLE_ENDIAN; + want = BFD_ENDIAN_LITTLE; if (TARGET_BYTE_ORDER_AUTO) target_byte_order = want; else if (TARGET_BYTE_ORDER != want) @@ -771,7 +771,7 @@ initialize_current_architecture (void) info.byte_order = BIG_ENDIAN; break; case BFD_ENDIAN_LITTLE: - info.byte_order = LITTLE_ENDIAN; + info.byte_order = BFD_ENDIAN_LITTLE; break; default: break; @@ -785,7 +785,7 @@ initialize_current_architecture (void) if (chp != NULL && chp - 2 >= target_name && strncmp (chp - 2, "el", 2) == 0) - info.byte_order = LITTLE_ENDIAN; + info.byte_order = BFD_ENDIAN_LITTLE; } if (info.byte_order == 0) { diff --git a/gdb/config/alpha/tm-alpha.h b/gdb/config/alpha/tm-alpha.h index 60c0b80cf93..f5f349760fe 100644 --- a/gdb/config/alpha/tm-alpha.h +++ b/gdb/config/alpha/tm-alpha.h @@ -34,7 +34,7 @@ struct value; struct symbol; #if !defined (TARGET_BYTE_ORDER) -#define TARGET_BYTE_ORDER LITTLE_ENDIAN +#define TARGET_BYTE_ORDER BFD_ENDIAN_LITTLE #endif /* Redefine some target bit sizes from the default. */ diff --git a/gdb/config/arm/tm-arm.h b/gdb/config/arm/tm-arm.h index e4271dae19e..3c1535022b0 100644 --- a/gdb/config/arm/tm-arm.h +++ b/gdb/config/arm/tm-arm.h @@ -32,7 +32,7 @@ struct value; /* Target byte order on ARM defaults to selectable, and defaults to little endian. */ #define TARGET_BYTE_ORDER_SELECTABLE_P 1 -#define TARGET_BYTE_ORDER_DEFAULT LITTLE_ENDIAN +#define TARGET_BYTE_ORDER_DEFAULT BFD_ENDIAN_LITTLE /* IEEE format floating point. */ #define IEEE_FLOAT (1) diff --git a/gdb/config/i386/tm-i386.h b/gdb/config/i386/tm-i386.h index 8407057ba37..d40a5f80e87 100644 --- a/gdb/config/i386/tm-i386.h +++ b/gdb/config/i386/tm-i386.h @@ -32,7 +32,7 @@ struct frame_saved_regs; struct value; struct type; -#define TARGET_BYTE_ORDER LITTLE_ENDIAN +#define TARGET_BYTE_ORDER BFD_ENDIAN_LITTLE /* 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 diff --git a/gdb/config/i960/tm-i960.h b/gdb/config/i960/tm-i960.h index f47b880e8a5..b6ed313456d 100644 --- a/gdb/config/i960/tm-i960.h +++ b/gdb/config/i960/tm-i960.h @@ -39,7 +39,7 @@ #define DBX_PARM_SYMBOL_CLASS(type) ((type == N_LSYM)? LOC_LOCAL_ARG: LOC_ARG) /* Byte order is configurable, but this machine runs little-endian. */ -#define TARGET_BYTE_ORDER LITTLE_ENDIAN +#define TARGET_BYTE_ORDER BFD_ENDIAN_LITTLE /* We have IEEE floating point, if we have any float at all. */ diff --git a/gdb/config/ia64/tm-ia64.h b/gdb/config/ia64/tm-ia64.h index 326729f601d..37e4d72a34e 100644 --- a/gdb/config/ia64/tm-ia64.h +++ b/gdb/config/ia64/tm-ia64.h @@ -29,7 +29,7 @@ /* ia64 is little endian by default */ -#define TARGET_BYTE_ORDER LITTLE_ENDIAN +#define TARGET_BYTE_ORDER BFD_ENDIAN_LITTLE /* 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 diff --git a/gdb/config/mcore/tm-mcore.h b/gdb/config/mcore/tm-mcore.h index 0fae6ac1f03..22631c00f24 100644 --- a/gdb/config/mcore/tm-mcore.h +++ b/gdb/config/mcore/tm-mcore.h @@ -21,7 +21,7 @@ #include "regcache.h" /* The mcore is little endian (by default) */ -#define TARGET_BYTE_ORDER_DEFAULT LITTLE_ENDIAN +#define TARGET_BYTE_ORDER_DEFAULT BFD_ENDIAN_LITTLE /* All registers are 32 bits */ #define REGISTER_SIZE 4 diff --git a/gdb/config/mips/tm-wince.h b/gdb/config/mips/tm-wince.h index 10e2eeb5d2b..737ccc60bc5 100644 --- a/gdb/config/mips/tm-wince.h +++ b/gdb/config/mips/tm-wince.h @@ -30,6 +30,6 @@ void wince_software_single_step (unsigned int, int); #undef TARGET_BYTE_ORDER_SELECTABLE -#define TARGET_BYTE_ORDER LITTLE_ENDIAN +#define TARGET_BYTE_ORDER BFD_ENDIAN_LITTLE #endif /* TM_WINCE_H */ diff --git a/gdb/config/mn10200/tm-mn10200.h b/gdb/config/mn10200/tm-mn10200.h index 7018d5662c2..4d416c51921 100644 --- a/gdb/config/mn10200/tm-mn10200.h +++ b/gdb/config/mn10200/tm-mn10200.h @@ -26,7 +26,7 @@ #include "regcache.h" /* The mn10200 is little endian. */ -#define TARGET_BYTE_ORDER LITTLE_ENDIAN +#define TARGET_BYTE_ORDER BFD_ENDIAN_LITTLE /* ints are only 16bits on the mn10200. */ #undef TARGET_INT_BIT diff --git a/gdb/config/ns32k/tm-umax.h b/gdb/config/ns32k/tm-umax.h index 5f9d2b985ea..9f1fb31eb24 100644 --- a/gdb/config/ns32k/tm-umax.h +++ b/gdb/config/ns32k/tm-umax.h @@ -23,7 +23,7 @@ /* This is also included by tm-ns32km3.h, as well as being used by umax. */ -#define TARGET_BYTE_ORDER LITTLE_ENDIAN +#define TARGET_BYTE_ORDER BFD_ENDIAN_LITTLE /* Need to get function ends by adding this to epilogue address from .bf record, not using x_fsize field. */ diff --git a/gdb/config/powerpc/tm-ppcle-eabi.h b/gdb/config/powerpc/tm-ppcle-eabi.h index a6b16719cc6..1eb64701de0 100644 --- a/gdb/config/powerpc/tm-ppcle-eabi.h +++ b/gdb/config/powerpc/tm-ppcle-eabi.h @@ -26,6 +26,6 @@ #include "powerpc/tm-ppc-eabi.h" #undef TARGET_BYTE_ORDER_DEFAULT -#define TARGET_BYTE_ORDER_DEFAULT LITTLE_ENDIAN +#define TARGET_BYTE_ORDER_DEFAULT BFD_ENDIAN_LITTLE #endif /* TM_PPCLE_EABI_H */ diff --git a/gdb/config/sh/tm-wince.h b/gdb/config/sh/tm-wince.h index 4c4869af7a3..ddebbd2714e 100644 --- a/gdb/config/sh/tm-wince.h +++ b/gdb/config/sh/tm-wince.h @@ -29,6 +29,6 @@ #define SOFTWARE_SINGLE_STEP(sig, bp_p) wince_software_single_step (sig, bp_p) void wince_software_single_step (unsigned int, int); #undef TARGET_BYTE_ORDER_SELECTABLE -#define TARGET_BYTE_ORDER LITTLE_ENDIAN +#define TARGET_BYTE_ORDER BFD_ENDIAN_LITTLE #endif /* TM_WINCE_H */ diff --git a/gdb/config/v850/tm-v850.h b/gdb/config/v850/tm-v850.h index 83e755edaaa..69f8491ad2f 100644 --- a/gdb/config/v850/tm-v850.h +++ b/gdb/config/v850/tm-v850.h @@ -21,7 +21,7 @@ #include "regcache.h" -#define TARGET_BYTE_ORDER LITTLE_ENDIAN +#define TARGET_BYTE_ORDER BFD_ENDIAN_LITTLE #define NUM_REGS 66 diff --git a/gdb/config/vax/tm-vax.h b/gdb/config/vax/tm-vax.h index 867844bc7c6..65f8d7048ea 100644 --- a/gdb/config/vax/tm-vax.h +++ b/gdb/config/vax/tm-vax.h @@ -21,7 +21,7 @@ #include "regcache.h" -#define TARGET_BYTE_ORDER LITTLE_ENDIAN +#define TARGET_BYTE_ORDER BFD_ENDIAN_LITTLE /* Offset from address of function to start of its code. Zero on most machines. */ diff --git a/gdb/cris-tdep.c b/gdb/cris-tdep.c index cb5305a3771..d3376b5ae6a 100644 --- a/gdb/cris-tdep.c +++ b/gdb/cris-tdep.c @@ -3799,7 +3799,7 @@ cris_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches) /* INIT shall ensure that the INFO.BYTE_ORDER is non-zero. */ switch (info.byte_order) { - case LITTLE_ENDIAN: + case BFD_ENDIAN_LITTLE: /* Ok. */ break; diff --git a/gdb/d10v-tdep.c b/gdb/d10v-tdep.c index fa55d464ef5..4bb9c9d570e 100644 --- a/gdb/d10v-tdep.c +++ b/gdb/d10v-tdep.c @@ -1528,7 +1528,7 @@ d10v_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches) set_gdbarch_double_format (gdbarch, &floatformat_ieee_single_big); set_gdbarch_long_double_format (gdbarch, &floatformat_ieee_double_big); break; - case LITTLE_ENDIAN: + case BFD_ENDIAN_LITTLE: set_gdbarch_float_format (gdbarch, &floatformat_ieee_single_little); set_gdbarch_double_format (gdbarch, &floatformat_ieee_single_little); set_gdbarch_long_double_format (gdbarch, &floatformat_ieee_double_little); diff --git a/gdb/defs.h b/gdb/defs.h index b1512a2e39c..48adef5139d 100644 --- a/gdb/defs.h +++ b/gdb/defs.h @@ -1223,7 +1223,7 @@ extern void *alloca (); #endif /* Not GNU C */ #endif /* alloca not defined */ -/* Get a definition of BIG_ENDIAN and LITTLE_ENDIAN. */ +/* Get a definition of BIG_ENDIAN and BFD_ENDIAN_LITTLE. */ /* FIXME: cagney/2001-10-31: GDB should just use BFD's definitions. */ #ifdef HAVE_ENDIAN_H @@ -1234,10 +1234,6 @@ extern void *alloca (); #define BIG_ENDIAN 4321 #endif -#if !defined (LITTLE_ENDIAN) -#define LITTLE_ENDIAN 1234 -#endif - /* Dynamic target-system-dependent parameters for GDB. */ #include "gdbarch.h" #if (GDB_MULTI_ARCH == 0) diff --git a/gdb/doc/ChangeLog b/gdb/doc/ChangeLog index 3a8fc7440eb..9be00483bc0 100644 --- a/gdb/doc/ChangeLog +++ b/gdb/doc/ChangeLog @@ -1,3 +1,8 @@ +2001-12-15 Andrew Cagney <ac131313@redhat.com> + + * gdbint.texinfo (Target Architecture Definition): Replace + LITTLE_ENDIAN with BFD_ENDIAN_LITTLE. + 2001-12-01 Andrew Cagney <ac131313@redhat.com> * gdbint.texinfo (Host Definition): Delete documentation on diff --git a/gdb/doc/gdbint.texinfo b/gdb/doc/gdbint.texinfo index efe9e8e0fb2..83dfb29ea9e 100644 --- a/gdb/doc/gdbint.texinfo +++ b/gdb/doc/gdbint.texinfo @@ -42,7 +42,7 @@ Software Foundation raise funds for GNU development.'' @page @tex \def\$#1${{#1}} % Kluge: collect RCS revision info without $...$ -\xdef\manvers{\$Revision: 1.47 $} % For use in headers, footers too +\xdef\manvers{\$Revision: 1.48 $} % For use in headers, footers too {\parskip=0pt \hfill Cygnus Solutions\par \hfill \manvers\par @@ -3488,13 +3488,13 @@ current sources.) @item TARGET_BYTE_ORDER_DEFAULT @findex TARGET_BYTE_ORDER_DEFAULT The ordering of bytes in the target. This must be either -@code{BIG_ENDIAN} or @code{LITTLE_ENDIAN}. This macro replaces +@code{BIG_ENDIAN} or @code{BFD_ENDIAN_LITTLE}. This macro replaces @code{TARGET_BYTE_ORDER} which is deprecated. @item TARGET_BYTE_ORDER_SELECTABLE_P @findex TARGET_BYTE_ORDER_SELECTABLE_P Non-zero if the target has both @code{BIG_ENDIAN} and -@code{LITTLE_ENDIAN} variants. This macro replaces +@code{BFD_ENDIAN_LITTLE} variants. This macro replaces @code{TARGET_BYTE_ORDER_SELECTABLE} which is deprecated. @item TARGET_CHAR_BIT diff --git a/gdb/gdbarch.c b/gdb/gdbarch.c index 64cecbad4cf..72737e738af 100644 --- a/gdb/gdbarch.c +++ b/gdb/gdbarch.c @@ -341,6 +341,7 @@ struct gdbarch startup_gdbarch = 0, 0, 0, + 0, generic_get_saved_register, 0, 0, @@ -4725,7 +4726,7 @@ gdbarch_update_p (struct gdbarch_info info) if (info.byte_order == 0 && info.abfd != NULL) info.byte_order = (bfd_big_endian (info.abfd) ? BIG_ENDIAN - : bfd_little_endian (info.abfd) ? LITTLE_ENDIAN + : bfd_little_endian (info.abfd) ? BFD_ENDIAN_LITTLE : 0); /* From the current target. */ if (info.byte_order == 0) @@ -4745,7 +4746,7 @@ gdbarch_update_p (struct gdbarch_info info) "gdbarch_update: info.byte_order %d (%s)\n", info.byte_order, (info.byte_order == BIG_ENDIAN ? "big" - : info.byte_order == LITTLE_ENDIAN ? "little" + : info.byte_order == BFD_ENDIAN_LITTLE ? "little" : "default")); fprintf_unfiltered (gdb_stdlog, "gdbarch_update: info.abfd 0x%lx\n", diff --git a/gdb/gdbarch.sh b/gdb/gdbarch.sh index 28395a86477..c474232790e 100755 --- a/gdb/gdbarch.sh +++ b/gdb/gdbarch.sh @@ -2044,7 +2044,7 @@ gdbarch_update_p (struct gdbarch_info info) if (info.byte_order == 0 && info.abfd != NULL) info.byte_order = (bfd_big_endian (info.abfd) ? BIG_ENDIAN - : bfd_little_endian (info.abfd) ? LITTLE_ENDIAN + : bfd_little_endian (info.abfd) ? BFD_ENDIAN_LITTLE : 0); /* From the current target. */ if (info.byte_order == 0) @@ -2064,7 +2064,7 @@ gdbarch_update_p (struct gdbarch_info info) "gdbarch_update: info.byte_order %d (%s)\n", info.byte_order, (info.byte_order == BIG_ENDIAN ? "big" - : info.byte_order == LITTLE_ENDIAN ? "little" + : info.byte_order == BFD_ENDIAN_LITTLE ? "little" : "default")); fprintf_unfiltered (gdb_stdlog, "gdbarch_update: info.abfd 0x%lx\n", diff --git a/gdb/remote-rdp.c b/gdb/remote-rdp.c index 22f5b3e4fd4..b531047118a 100644 --- a/gdb/remote-rdp.c +++ b/gdb/remote-rdp.c @@ -349,7 +349,7 @@ rdp_init (int cold, int tty) case SERIAL_TIMEOUT: break; case RDP_RES_VALUE_LITTLE_ENDIAN: - target_byte_order = LITTLE_ENDIAN; + target_byte_order = BFD_ENDIAN_LITTLE; sync = 1; break; case RDP_RES_VALUE_BIG_ENDIAN: diff --git a/gdb/remote-sim.c b/gdb/remote-sim.c index 3e515c13af8..caba037d3b5 100644 --- a/gdb/remote-sim.c +++ b/gdb/remote-sim.c @@ -480,7 +480,7 @@ gdbsim_open (char *args, int from_tty) case BIG_ENDIAN: strcat (arg_buf, " -E big"); break; - case LITTLE_ENDIAN: + case BFD_ENDIAN_LITTLE: strcat (arg_buf, " -E little"); break; default: diff --git a/gdb/sh-tdep.c b/gdb/sh-tdep.c index 65bc62b38c4..5a555b1e301 100644 --- a/gdb/sh-tdep.c +++ b/gdb/sh-tdep.c @@ -1034,7 +1034,7 @@ sh3e_sh4_extract_return_value (struct type *type, char *regbuf, char *valbuf) if (len == 8 && TYPE_CODE (type) == TYPE_CODE_FLT) { DOUBLEST val; - if (TARGET_BYTE_ORDER == LITTLE_ENDIAN) + if (TARGET_BYTE_ORDER == BFD_ENDIAN_LITTLE) floatformat_to_doublest (&floatformat_ieee_double_littlebyte_bigword, (char *) regbuf + REGISTER_BYTE (return_register), &val); @@ -1536,7 +1536,7 @@ sh_default_register_virtual_type (int reg_nr) int sh_sh4_register_convertible (int nr) { - if (TARGET_BYTE_ORDER == LITTLE_ENDIAN) + if (TARGET_BYTE_ORDER == BFD_ENDIAN_LITTLE) return (gdbarch_tdep (current_gdbarch)->DR0_REGNUM <= nr && nr <= gdbarch_tdep (current_gdbarch)->DR_LAST_REGNUM); else diff --git a/gdb/sparc-tdep.c b/gdb/sparc-tdep.c index 0a1d576a051..1910b1b182e 100644 --- a/gdb/sparc-tdep.c +++ b/gdb/sparc-tdep.c @@ -2063,7 +2063,7 @@ sparc32_extract_return_value (struct type *type, char *regbuf, char *valbuf) memcpy (valbuf, ®buf[O0_REGNUM * regsize + (typelen >= regsize - || TARGET_BYTE_ORDER == LITTLE_ENDIAN ? 0 + || TARGET_BYTE_ORDER == BFD_ENDIAN_LITTLE ? 0 : regsize - typelen)], typelen); } @@ -2202,7 +2202,7 @@ sparc_target_architecture_hook (const bfd_arch_info_type *ap) { if (TARGET_BYTE_ORDER_SELECTABLE_P) { - target_byte_order = LITTLE_ENDIAN; + target_byte_order = BFD_ENDIAN_LITTLE; bi_endian = 1; } else |