* GDB stub questions
@ 2006-01-30 20:23 Mitchell Fang
2006-01-31 18:09 ` Mark Kettenis
2006-01-31 18:26 ` Daniel Jacobowitz
0 siblings, 2 replies; 3+ messages in thread
From: Mitchell Fang @ 2006-01-30 20:23 UTC (permalink / raw)
To: gdb
I have a question about the GDB stub. Where does the stub run? Is it
on the host machine, the target board, or the JTAG controller.
I'm working on a project to connect GDB to a PowerPC4xx board using a
JTAG controller. It's suppose to generic enough to support different
types of controller (USB, ethernet, PCI...etc). I have .dll's for the
controllers. I would like to avoid having another program running to
convert the GDB remote protocol to JTAG commands.
Is it possible to edit GDB so that it automatically uses the JTAG
controller's .dll's directly? I am currently thinking no. From what I
understand about GDB, I think that I need to use a stub since I'm
doing a debugging remotely. I've been reading the GDB user manual
about implementing a remote stub but not really getting it. But I
don't totally understand how a stub works and where it is suppose to
run so I'm kinda stuck. My thinking is that the stub is suppose to
run on the target board. But then how do you build/make the stub an
application so that it's able to run on the target board? I think I'm
just missing the overall picture and I wanted to make sure that I
start off in the right direction.
Any input would be appreciated.
Thanks,
Mitchell
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: GDB stub questions
2006-01-30 20:23 GDB stub questions Mitchell Fang
@ 2006-01-31 18:09 ` Mark Kettenis
2006-01-31 18:26 ` Daniel Jacobowitz
1 sibling, 0 replies; 3+ messages in thread
From: Mark Kettenis @ 2006-01-31 18:09 UTC (permalink / raw)
To: mitchell.fang; +Cc: gdb
> Date: Mon, 30 Jan 2006 12:16:07 -0800
> From: Mitchell Fang <mitchell.fang@gmail.com>
>
> I have a question about the GDB stub. Where does the stub run? Is it
> on the host machine, the target board, or the JTAG controller.
Wherever you like!
Mark
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: GDB stub questions
2006-01-30 20:23 GDB stub questions Mitchell Fang
2006-01-31 18:09 ` Mark Kettenis
@ 2006-01-31 18:26 ` Daniel Jacobowitz
1 sibling, 0 replies; 3+ messages in thread
From: Daniel Jacobowitz @ 2006-01-31 18:26 UTC (permalink / raw)
To: Mitchell Fang; +Cc: gdb
On Mon, Jan 30, 2006 at 12:16:07PM -0800, Mitchell Fang wrote:
> I have a question about the GDB stub. Where does the stub run? Is it
> on the host machine, the target board, or the JTAG controller.
This depends on your needs. A stub can typically communicate over TCP
or serial from the stub; over TCP from a stand-alone JTAG unit; or over
TCP on the localhost interface of the host (often talking to a
simulator or a parallel/USB JTAG unit).
If you are using JTAG, it will have to be the second or third of
my listed options; in your case, it sounds like you want the third,
a local daemon.
> Is it possible to edit GDB so that it automatically uses the JTAG
> controller's .dll's directly?
Please do not attempt to do this. We used to add remote targets
directly to GDB; now we are trying to componentize them across the
barrier of the standard remote debug protocol. For one thing,
you end up with tricky-to-maintain code directly in GDB; for another,
the DLLs are often legally encumbered in ways that make linking
them to GDB inadvisable.
--
Daniel Jacobowitz
CodeSourcery
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2006-01-30 20:23 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-01-30 20:23 GDB stub questions Mitchell Fang
2006-01-31 18:09 ` Mark Kettenis
2006-01-31 18:26 ` Daniel Jacobowitz
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox