Re: [rfc/rft] ppc gdbserver: autodetect AltiVec and SPE

Ulrich Weigand
2008-04-21T12:55:52Z

Thiago Jung Bauermann wrote:
> On Sun, 2008-04-20 at 10:27 -0400, Daniel Jacobowitz wrote:
> > > Is such way of compiling 32-bit GDB in a ppc64 machine with 32-bit
> > > default gcc not supported? Must one always use --target option to
> > > configure in such case?
> >
> > I see. Anything is supported that we're willing to fix... The
> > simplest possible fix would be to add the e500 objects. Does
> > gdbserver work OK with this patch?
>
> Yes, it compiled fine. Thanks!

Sorry for the breakage. My understanding is that building a 32-bit
powerpc64-linux gdbserver was never supported, and would fail at
run time because ptrace does not support accessing 64-bit inferior
registers from a 32-bit debugger (at least not using the standard
ptrace functions).

However, with bi-arch support, I guess it now would actually work
at least for debugging 32-bit inferiors.

I'm wondering whether it wouldn't make sense now to drop the
configure-time distinction between powerpc-linux and powerpc64-linux
for gdbserver (just like there already is no such distinction
for GDB itself).

This would mean no matter whether you configure for powerpc-linux
or for powerpc64-linux, the resulting gdbserver would always support
32-bit inferiors, and would in addition support 64-bit inferiors iff
it was built as a 64-bit executable.

Dan, what do you think?

Bye,
Ulrich

--
Dr. Ulrich Weigand
GNU Toolchain for Linux on System z and Cell BE
Ulrich.Weigand@de.ibm.com