This is the mail archive of the
gdb@sourceware.org
mailing list for the GDB project.
Re: How to use gdbserver for X86 host with arm-linux target ?
- From: Doug Evans <dje at google dot com>
- To: Pedro Alves <pedro at codesourcery dot com>
- Cc: gdb at sourceware dot org, karl leplat <karl dot leplat at parrot dot com>
- Date: Tue, 13 Sep 2011 10:28:14 -0700
- Subject: Re: How to use gdbserver for X86 host with arm-linux target ?
- References: <4E6DEBD1.4080007@parrot.com> <201109121448.18875.pedro@codesourcery.com>
On Mon, Sep 12, 2011 at 6:48 AM, Pedro Alves <pedro@codesourcery.com> wrote:
> On Monday 12 September 2011 12:24:01, karl leplat wrote:
>> Hi,
>>
>> When i inserted a hardware breakpoint, i got the result :
>>
>> Side gdb:
>> Warning:
>> Cannot insert hardware breakpoint 1.
>> Could not insert hardware breakpoints:
>> You may have requested too many hardware breakpoints/watchpoints.
>>
>> Side gdbserver:
>> In the file: "gdbserver/linux-arm-low.c" , i have seen that the target
>> has not registered the function insert_point.
>>
>> Is it normal ?
>
> Yes. ?The arm-linux gdbserver port was never taught about
> managing breakpoints itself. ?When that callback is not installed,
> gdb itself inserts breakpoints in program memory, using regular
> memory writes to plant the breakpoint insn.
>
>> Is there a solution ?
>
> There's code in native arm port of gdb to support hardware breakpoints
> and watchpoints (arm-linux-nat.c). ?Someone interested should be able
> to port it to gdbserver.
Seems like this another example where gdb suffers from having two code
bases (gdb, gdbserver) to implement the same functionality.
[always on the lookout for such things ...]