This is the mail archive of the
gdb@sourceware.org
mailing list for the GDB project.
Re: Fwd: Porting GDB to new architecture
- From: Jeremy Bennett <jeremy dot bennett at embecosm dot com>
- To: gdb at sourceware dot org
- Cc: Dalibor Kovacevic <malonj at gmail dot com>
- Date: Thu, 11 Nov 2010 15:51:40 +0000
- Subject: Re: Fwd: Porting GDB to new architecture
- References: <AANLkTi=kw0fJaRDKrppfq0y=SrA2URGGnSp08whozgp0@mail.gmail.com> <AANLkTi=fZT=p=ALxATS6wn5q1h=9_S6sHoMzZM8GPs+F@mail.gmail.com>
- Reply-to: jeremy dot bennett at embecosm dot com
On Thu, 2010-11-11 at 15:43 +0100, Dalibor Kovacevic wrote:
> I'm porting gdb 7.2 to a new architecture and I need a few tips to get
> me started. I have read all about porting gdb that google search found
> on that subject. The HOW TO from Jeremy Bennett helped me allot to
> understand what I need to do. But before the start of porting I was
> wondering could someone help me choose the starting template from
> already ported architectures. Mine is a combination of DSP
> and a microcontroller, binutils are already ported so i have BFD, it
> will be debugged via stub.
Hi Dalibor,
Glad you found the HOWTO useful. I need to update it for GDB 7.x. In
particular the frame handling has changed, so the functions use THIS
frame as the handle, rather than the NEXT frame. The function names have
changed accordingly.
I took my examples from the OpenRISC 1000, which is a MIPS like RISC
architecture. It's not part of the official GDB distribution (yet!), but
you can find the source code at
http://opencores.org/openrisc,gnu_toolchain
Because I used it in the HOWTO, the code is commented rather more
verbosely than other ports, so you may find it a useful example to look
at. There is a 7.2 version, which will help you with the new function
names.
HTH,
Jeremy
--
Tel: +44 (1590) 610184
Cell: +44 (7970) 676050
SkypeID: jeremybennett
Email: jeremy.bennett@embecosm.com
Web: www.embecosm.com