diff options
Diffstat (limited to 'gdb/c-lang.c')
-rw-r--r-- | gdb/c-lang.c | 26 |
1 files changed, 17 insertions, 9 deletions
diff --git a/gdb/c-lang.c b/gdb/c-lang.c index 8dac4f5..32b023d 100644 --- a/gdb/c-lang.c +++ b/gdb/c-lang.c @@ -313,41 +313,49 @@ c_create_fundamental_type (struct objfile *objfile, int typeid) break; case FT_FLOAT: type = init_type (TYPE_CODE_FLT, - TARGET_FLOAT_BIT / TARGET_CHAR_BIT, + gdbarch_float_bit (current_gdbarch) / TARGET_CHAR_BIT, 0, "float", objfile); break; case FT_DBL_PREC_FLOAT: type = init_type (TYPE_CODE_FLT, - TARGET_DOUBLE_BIT / TARGET_CHAR_BIT, + gdbarch_double_bit (current_gdbarch) / TARGET_CHAR_BIT, 0, "double", objfile); break; case FT_EXT_PREC_FLOAT: type = init_type (TYPE_CODE_FLT, - TARGET_LONG_DOUBLE_BIT / TARGET_CHAR_BIT, + gdbarch_long_double_bit (current_gdbarch) + / TARGET_CHAR_BIT, 0, "long double", objfile); break; case FT_COMPLEX: type = init_type (TYPE_CODE_FLT, - 2 * TARGET_FLOAT_BIT / TARGET_CHAR_BIT, + 2 * gdbarch_float_bit (current_gdbarch) + / TARGET_CHAR_BIT, 0, "complex float", objfile); TYPE_TARGET_TYPE (type) - = init_type (TYPE_CODE_FLT, TARGET_FLOAT_BIT / TARGET_CHAR_BIT, + = init_type (TYPE_CODE_FLT, + gdbarch_float_bit (current_gdbarch) / TARGET_CHAR_BIT, 0, "float", objfile); break; case FT_DBL_PREC_COMPLEX: type = init_type (TYPE_CODE_FLT, - 2 * TARGET_DOUBLE_BIT / TARGET_CHAR_BIT, + 2 * gdbarch_double_bit (current_gdbarch) + / TARGET_CHAR_BIT, 0, "complex double", objfile); TYPE_TARGET_TYPE (type) - = init_type (TYPE_CODE_FLT, TARGET_DOUBLE_BIT / TARGET_CHAR_BIT, + = init_type (TYPE_CODE_FLT, + gdbarch_double_bit (current_gdbarch) / TARGET_CHAR_BIT, 0, "double", objfile); break; case FT_EXT_PREC_COMPLEX: type = init_type (TYPE_CODE_FLT, - 2 * TARGET_LONG_DOUBLE_BIT / TARGET_CHAR_BIT, + 2 * gdbarch_long_double_bit (current_gdbarch) + / TARGET_CHAR_BIT, 0, "complex long double", objfile); TYPE_TARGET_TYPE (type) - = init_type (TYPE_CODE_FLT, TARGET_LONG_DOUBLE_BIT / TARGET_CHAR_BIT, + = init_type (TYPE_CODE_FLT, + gdbarch_long_double_bit (current_gdbarch) + / TARGET_CHAR_BIT, 0, "long double", objfile); break; case FT_TEMPLATE_ARG: |