This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [RFA] (riscv/ada) fix error when calling functions with range argument
- From: Andrew Burgess <andrew dot burgess at embecosm dot com>
- To: Tom Tromey <tom at tromey dot com>
- Cc: Joel Brobecker <brobecker at adacore dot com>, gdb-patches at sourceware dot org, KONRAD Frederic <konrad at adacore dot com>
- Date: Wed, 13 Feb 2019 10:30:55 +0000
- Subject: Re: [RFA] (riscv/ada) fix error when calling functions with range argument
- References: <1549805906-1627-1-git-send-email-brobecker@adacore.com> <87wom56j7u.fsf@tromey.com>
* Tom Tromey <tom@tromey.com> [2019-02-12 09:54:13 -0700]:
> >>>>> "Joel" == Joel Brobecker <brobecker@adacore.com> writes:
>
> Joel> gdb/ChangeLog:
> Joel> * gdb/riscv-rdep.c (riscv_type_alignment): Handle TYPE_CODE_RANGE.
> Joel> Tested on riscv64-elf using AdaCore's testsuite.
> Joel> OK to apply?
>
> I don't have any issue with this, but I do wonder if
> riscv_type_alignment can be removed and/or simplified in favor
> type_align and the gdbarch method.
>
> I see several ports have this issue. type_align should be preferred,
> IMO, because it respects any additional alignment specified in the
> DWARF. I assume there are latent bugs in function calling on various
> platforms caused by this, though I haven't checked.
I'll test changing RISC-V over to using gdbtypes.c:type_align.
Thanks,
Andrew