[PATCH] [AArch64] Mark single precision pseudo registers unavailable if invalid
Yao Qi
qiyaoltc@gmail.com
Wed Jul 15 14:01:00 GMT 2015
Pierre Langlois <pierre.langlois@arm.com> writes:
> It turns out GDB does not check if S registers are valid before returning
> a value for them. It should return <unavailable> in this case.
Yes, your fix is correct, however ...
>
> Thanks,
> Pierre
>
> gdb/ChangeLog:
>
> * aarch64-tdep.c (aarch64_pseudo_read_value): Mark S register as
> unavailable if invalid.
... when I read your patch, I am wondering why does aarch64 implement
gdbarch method pseudo_register_read_value rather than
pseudo_register_read. If we implement the pseudo_register_read, the
caller will mark the value unavailable according to its return value.
pseudo_register_read_value was added to handle partially available
registers by https://sourceware.org/ml/gdb-patches/2011-07/msg00351.html
but I don't think of a case that some aarch64 register is partially
available. Maybe, another fix to this problem is to implement
pseudo_register_read instead of pseudo_register_read_value.
--
Yao (齐尧)
More information about the Gdb-patches
mailing list