2007-06-12 Markus Deuling <deuling@de.ibm.com>

* gdbarch.sh (TARGET_SHORT_BIT): Replace by gdbarch_int_bit.
	* ada-lang.c (ada_create_fundamental_type)
	(ada_language_arch_info): Likewise.
	* c-lang.c (c_create_fundamental_type): Likewise.
	* f-lang.c (f_create_fundamental_type, build_fortran_types): Likewise.
	* gdbtypes.c (build_gdbtypes, gdbtypes_post_init): Likewise.
	* m2-lang.c (m2_create_fundamental_type): Likewise.
	* objc-lang.c (objc_create_fundamental_type): Likewise.
	* p-lang.c (pascal_create_fundamental_type): Likewise.
	* gdbarch.sh (TARGET_INT_BIT): Replace by gdbarch_int_bit.
	* c-exp.y (parse_number): Likewise.
	* objc-exp.y (parse_number): Likewise.
	* ada-lex.l (processInt): Likewise.
	* f-exp.y (parse_number): Likewise.
	* p-exp.y (parse_number): Likewise.
	* ada-lang.c (ada_create_fundamental_type, ada_language_arch_info)
	(gdbtypes_post_init, build_gdbtypes): Likewise.
	* p-lang.c (pascal_create_fundamental_type): Likewise.
	* parse.c (build_parse): Likewise.
	* xcoffread.c (_initialize_xcoffread): Likewise.
	* stabsread.c (define_symbol, read_one_struct_field, read_enum_type)
	(read_range_type): Likewise.
	* objc-lang.c (objc_create_fundamental_type): Likewise.
	* f-lang.c (build_fortran_types, f_create_fundamental_type): Likewise.
	* m2-lang.c (m2_create_fundamental_type, _initialize_m2_language)
	(m2_create_fundamental_type): Likewise.
	* c-lang.c (c_create_fundamental_type): Likewise.
	* coffread.c (coff_read_enum_type): Likewise.
	* mdebugread.c (parse_symbol, _initialize_mdebugread): Likewise.
	* dwarf2read.c (new_symbol): Likewise.
	* gdbarch.sh (TARGET_LONG_BIT): Replace by gdbarch_long_bit.
	* c-exp.y (parse_number): Likewise.
	* objc-exp.y (parse_number): Likewise.
	* ada-lex.l (processInt): Likewise.
	* f-exp.y (parse_number): Likewise.
	* p-exp.y (parse_number): Likewise.
	* valarith.c (value_binop): Likewise.
	* symfile.c (read_target_long_array, simple_overlay_update_1): Likewise.
	* ada-lang.c (ada_create_fundamental_type)
	(ada_language_arch_info): Likewise.
	* gdbtypes.c (build_gdbtypes, gdbtypes_post_init): Likewise.
	* symfile.c (TARGET_LONG_BYTES): Likewise.
	* p-lang.c (pascal_create_fundamental_type): Likewise.
	* objc-lang.c (objc_create_fundamental_type): Likewise.
	* m2-lang.c (m2_create_fundamental_type): Likewise.
	* f-lang.c (f_create_fundamental_type): Likewise.
	* c-lang.c (c_create_fundamental_type): Likewise.
	* coffread.c (decode_base_type): Likewise.
	* gdbarch.sh (TARGET_LONG_LONG_BIT): Replace by gdbarch_long_long_bit.
	* c-exp.y (parse_number): Likewise.
	* objc-exp.y (parse_number): Likewise.
	* p-exp.y (parse_number): Likewise.
	* ada-lang.c (ada_create_fundamental_type)
	(ada_language_arch_info): Likewise.
	* gdbtypes.c (gdbtypes_post_init, build_gdbtypes): Likewise.
	* stabsread.c (read_range_type): Likewise.
	* p-lang.c (pascal_create_fundamental_type): Likewise.
	* objc-lang.c (objc_create_fundamental_type): Likewise.
	* m2-lang.c (m2_create_fundamental_type): Likewise.
	* f-lang.c (f_create_fundamental_type): Likewise.
	* c-lang.c (c_create_fundamental_type): Likewise.
	* gdbarch.c, gdbarch.h: Regenerate.
This commit is contained in:
Ulrich Weigand
2007-06-12 15:33:04 +00:00
parent 272dfcfd78
commit 9a76efb656
24 changed files with 330 additions and 264 deletions

View File

@@ -984,12 +984,14 @@ define_symbol (CORE_ADDR valu, char *string, int desc, int type,
/* Call it "int" because this is mainly C lossage. */
if (pcc_promotion_type == NULL)
pcc_promotion_type =
init_type (TYPE_CODE_INT, TARGET_INT_BIT / TARGET_CHAR_BIT,
init_type (TYPE_CODE_INT,
gdbarch_int_bit (current_gdbarch) / TARGET_CHAR_BIT,
0, "int", NULL);
if (pcc_unsigned_promotion_type == NULL)
pcc_unsigned_promotion_type =
init_type (TYPE_CODE_INT, TARGET_INT_BIT / TARGET_CHAR_BIT,
init_type (TYPE_CODE_INT,
gdbarch_int_bit (current_gdbarch) / TARGET_CHAR_BIT,
TYPE_FLAG_UNSIGNED, "unsigned int", NULL);
/* If PCC says a parameter is a short or a char, it is
@@ -2840,7 +2842,8 @@ read_one_struct_field (struct field_info *fip, char **pp, char *p,
if ((FIELD_BITSIZE (fip->list->field)
== TARGET_CHAR_BIT * TYPE_LENGTH (field_type)
|| (TYPE_CODE (field_type) == TYPE_CODE_ENUM
&& FIELD_BITSIZE (fip->list->field) == TARGET_INT_BIT)
&& FIELD_BITSIZE (fip->list->field)
== gdbarch_int_bit (current_gdbarch))
)
&&
FIELD_BITPOS (fip->list->field) % 8 == 0)
@@ -3533,7 +3536,7 @@ read_enum_type (char **pp, struct type *type,
/* Now fill in the fields of the type-structure. */
TYPE_LENGTH (type) = TARGET_INT_BIT / HOST_CHAR_BIT;
TYPE_LENGTH (type) = gdbarch_int_bit (current_gdbarch) / HOST_CHAR_BIT;
TYPE_CODE (type) = TYPE_CODE_ENUM;
TYPE_FLAGS (type) &= ~TYPE_FLAG_STUB;
if (unsigned_enum)
@@ -3958,7 +3961,8 @@ read_range_type (char **pp, int typenums[2], int type_size,
/* It is unsigned int or unsigned long. */
/* GCC 2.3.3 uses this for long long too, but that is just a GDB 3.5
compatibility hack. */
return init_type (TYPE_CODE_INT, TARGET_INT_BIT / TARGET_CHAR_BIT,
return init_type (TYPE_CODE_INT,
gdbarch_int_bit (current_gdbarch) / TARGET_CHAR_BIT,
TYPE_FLAG_UNSIGNED, NULL, objfile);
}
@@ -4000,7 +4004,8 @@ read_range_type (char **pp, int typenums[2], int type_size,
of self_subrange. */
else if (n3 == 0 && n2 < 0
&& (self_subrange
|| n2 == -TARGET_LONG_LONG_BIT / TARGET_CHAR_BIT))
|| n2 == -gdbarch_long_long_bit
(current_gdbarch) / TARGET_CHAR_BIT))
return init_type (TYPE_CODE_INT, -n2, 0, NULL, objfile);
else if (n2 == -n3 - 1)
{
@@ -4031,7 +4036,8 @@ handle_true_range:
_("base type %d of range type is not defined"), rangenums[1]);
if (range_type_index == NULL)
range_type_index =
init_type (TYPE_CODE_INT, TARGET_INT_BIT / TARGET_CHAR_BIT,
init_type (TYPE_CODE_INT,
gdbarch_int_bit (current_gdbarch) / TARGET_CHAR_BIT,
0, "range type index type", NULL);
index_type = range_type_index;
}