This is the mail archive of the
mailing list for the GDB project.
Fw: gdbserver, remote serial protocol and endian issues
- From: "Paul Bartlett" <paul dot bartlett at st dot com>
- To: <gdb at sources dot redhat dot com>
- Date: Mon, 8 Apr 2002 16:40:20 +0100
- Subject: Fw: gdbserver, remote serial protocol and endian issues
----- Original Message -----
From: "Paul Bartlett" <email@example.com>
Sent: Monday, April 08, 2002 4:33 PM
Subject: Re: gdbserver, remote serial protocol and endian issues
> Hi Daniel,
> > I don't agree. Target registers are in
> > target-endianness when you read them off
> > the stack; they should be in target endianness
> > in memory. GDB has 'set endian little' and
> > 'set endian big', and the stub should just pass
> > them along however it gets them. gdbserver is
> > also meant to run in a native configuration,
> > where compile-time checks can tell you the
> > endianness.
> Well, maybe I'm guilty of not considering the
> general case - haven't thought it through yet.
> Our application connects to the H-UDI (JTAG)
> port of the SH4 for high speed (~20 MBits/s)
> access through the back door into the chip.
> The physical implementation includes a 32 bit
> shift register. What we notice is that if we
> change endianness then we have to endswap the
> 32 bit quantity that appears in the register
> before transferring it to the target machine
> reg. - it never actually gets into memory.
> > My first impression is that gdbserver is the
> > wrong tool for the job. Gdbserver is meant as
> > a remote stub for Unix-like systems. You're
> > not running it on a Unix-like system; you're
> > using it as a proxy, right? Since GDB already
> > has a stub to speak to the hardware monitor
> > on SH4 boards, as far as I'm aware.
> > This sounds like a job for rproxy
> > (http://world.std.com/~qqi) instead.
> Maybe we re-invented the wheel, some. Our
> implementation runs on a box equipped with
> cpu/flash/ram and ethernet and jtag interfaces.
> It does implement the remote protocol in much
> the same way that rproxy does, but also adds
> facilities like posix i/o through the debug
> Works well. We've used it for debugging both
> 'bare machine' embedded and rtos based apps.
> (I also brought up a linux kernel with it).