This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH PR gdb/22736] [aarch64] gdb crashes on a conditional breakpoint with cast return type
On 03/09/2018 07:11 PM, Alan Hayward wrote:
>> On 9 Mar 2018, at 16:44, Yao Qi <qiyaoltc@gmail.com> wrote:
>>
>> FWIW, this issue is *not* related to ifunc. As Alan described in
>> previous email, ifunc symbol is OK, but normal function symbol's target
>> type is NULL, because without debug information, GDB doesn't know the
>> symbol is a function or not. I thought about it, but I am not confident
>> that we can set symbol's target type (for example, set it void or int)
>> in absent of debug information.
>>
And how are we calling a function if we don't know its return type?
GDB won't let you, unless you add the cast. And then the question is,
why are we losing the cast-to type then? _That_ should the be return
type used, it sounds to me (but I still haven't reviewed in detail :-/ ).
>
> I’d just add that even with IFUNC the type will always be set to a pointer to an
> Int, regardless of the return type of the function.
Actually, I've changed that today in my series. /me almost done...
Thanks,
Pedro Alves