X-Git-Url: http://git.efficios.com/?a=blobdiff_plain;f=gdb%2Fs12z-tdep.c;h=607652c61a32ade9c3c4591481b91cfda49a04da;hb=refs%2Fheads%2Fconcurrent-displaced-stepping-2020-04-01;hp=a1c085cfbb03df46474a4c5bca8bd58502371a16;hpb=0a7b24850e0cba956bd836ecb1f60959cbf75087;p=deliverable%2Fbinutils-gdb.git diff --git a/gdb/s12z-tdep.c b/gdb/s12z-tdep.c index a1c085cfbb..607652c61a 100644 --- a/gdb/s12z-tdep.c +++ b/gdb/s12z-tdep.c @@ -1,5 +1,5 @@ /* Target-dependent code for the S12Z, for the GDB. - Copyright (C) 2018-2019 Free Software Foundation, Inc. + Copyright (C) 2018-2020 Free Software Foundation, Inc. This file is part of GDB. @@ -21,7 +21,7 @@ #include "defs.h" #include "arch-utils.h" -#include "dwarf2-frame.h" +#include "dwarf2/frame.h" #include "gdbsupport/errors.h" #include "frame-unwind.h" #include "gdbcore.h" @@ -30,7 +30,7 @@ #include "opcode/s12z.h" #include "trad-frame.h" #include "remote.h" -#include "../opcodes/s12z-opc.h" +#include "opcodes/s12z-opc.h" /* Two of the registers included in S12Z_N_REGISTERS are the CCH and CCL "registers" which are just views into @@ -147,7 +147,7 @@ s12z_fprintf_disasm (void *stream, const char *format, ...) return 0; } -struct disassemble_info +static struct disassemble_info s12z_disassemble_info (struct gdbarch *gdbarch) { struct disassemble_info di; @@ -170,7 +170,7 @@ struct mem_read_abstraction { struct mem_read_abstraction_base base; /* The parent struct. */ bfd_vma memaddr; /* Where to read from. */ - struct disassemble_info* info; /* The disassember to use for reading. */ + struct disassemble_info* info; /* The disassembler to use for reading. */ }; /* Advance the reader by one byte. */ @@ -614,9 +614,9 @@ s12z_return_value (struct gdbarch *gdbarch, struct value *function, struct type *type, struct regcache *regcache, gdb_byte *readbuf, const gdb_byte *writebuf) { - if (TYPE_CODE (type) == TYPE_CODE_STRUCT - || TYPE_CODE (type) == TYPE_CODE_UNION - || TYPE_CODE (type) == TYPE_CODE_ARRAY + if (type->code () == TYPE_CODE_STRUCT + || type->code () == TYPE_CODE_UNION + || type->code () == TYPE_CODE_ARRAY || TYPE_LENGTH (type) > 4) return RETURN_VALUE_STRUCT_CONVENTION; @@ -676,7 +676,7 @@ s12z_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches) set_gdbarch_register_type (gdbarch, s12z_register_type); frame_unwind_append_unwinder (gdbarch, &s12z_frame_unwind); - /* Currently, the only known producer for this archtecture, produces buggy + /* Currently, the only known producer for this architecture, produces buggy dwarf CFI. So don't append a dwarf unwinder until the situation is better understood. */ @@ -685,8 +685,9 @@ s12z_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches) return gdbarch; } +void _initialize_s12z_tdep (); void -_initialize_s12z_tdep (void) +_initialize_s12z_tdep () { gdbarch_register (bfd_arch_s12z, s12z_gdbarch_init, NULL); }