Re: [toolchain-devel] [PATCH v2] gdbserver: bfin: new port

Mike Frysinger
2010-12-15T12:55:38Z

On Wed, Dec 15, 2010 at 06:54, Andrew Stubbs wrote:
> On 14/12/10 17:25, Mike Frysinger wrote:
>>> I did start implementing something vaguely target independent (included
>>> >  in CodeSourcery SG++), but the state of the SH-2A kernel debug support
>>> >  put that project on the back burner, so it remains the bare minimum.
>>
>> i'm not asking for a finished project.  i would like to simply review the
>> code
>> you said you have already.  so where might one find your SuperH/FDPIC
>> gdb/gdbserver code ?
>
> The latest CodeSourcery SH-2A toolchain binaries and source can be
> downloaded from here:
> http://www.codesourcery.com/sgpp/lite/superh/portal/release1602
>
> I've attached my original patch. I didn't do the forward port when we
> updated GDB myself, so it may be out-of-date in a few places.

code looks good ... but there's one slight problem. it is binding to
the format gdbserver itself is being compiled as. in other words,
this code requires gdbserver itself to be compiled as FDPIC in order
to debug FDPIC applications. the current Blackfin code does not have
that restriction ... a FLAT gdbserver can debug a FDPIC app just fine.

but it seems this limitation is superfluous ... how about we change
the __FDPIC__ ifdef to:
#if defined(PTRACE_GETFDPIC_EXEC) && defined(PTRACE_GETFDPIC_INTERP)
...
#endif

do you have an idea of when you'll submit just the qXfer:fdpic support
? seems that these pieces can stand on their own just fine.
-mike