This is the mail archive of the
gdb-patches@sources.redhat.com
mailing list for the GDB project.
Re: Sumbitting ip2k port for review.
- From: Andrew Cagney <ac131313 at redhat dot com>
- To: Nick Kelsey <nickk at ubicom dot com>
- Cc: gdb-patches at sources dot redhat dot com
- Date: Wed, 11 Dec 2002 19:01:37 -0500
- Subject: Re: Sumbitting ip2k port for review.
- References: <067401c29cc8$fea5b4a0$f601a8c0@nkelseyxp>
[I've replied on GDB patches. For reference the code is attached.]
Hi all,
I would like to submit for review the ip2k port of gdb that I have been
working on for a while.
A copyright assignment has been signed by Ubicom.
Any feedback is welcome.
You'll probably want to look over the thread:
http://sources.redhat.com/ml/gdb/2002-02/msg00139.html
my follow up contains a check list.
The other question is who contributed to this work? `Java at
silicondust' appears to have being doing some stuff (or is that your
alter ego?). I believe David Taylor may have also worked on the file
ip2k-tdep.c in the past? I know that the problems he encountered with
the ip2k were one of the motivations behind overhauling pseudo-registers.
Having looked ip2k-tdep.c, some quick tweaks:
- the log messages should all go to gdb_stdlog, not gdb_stdout.
- instead of starting a message with "warning: ..." or similar, just
call warning(), or internal_error(), or ...
- The other targets have the command `set debug <cpu> <int>' to allow
the run-time control of the debug variable. That should be included.
Just borrow/tweak the code from mips-tdep.c say.
- it creates a tm-ip2k.h file. Per the above, all new targets need to
be pure multi-arched (with one shared library exception)
- ``__'' shouldn't be avoided as a prefix to symbols. A leading `_' is
reserved for the system's namespace.
- the registers are named ``r$80'' giving ``$r$80''. I don't know if
that is a good idea. Long term, as GDB's parser develops, you'll likely
find that this no longer works. Any reason to not simply use $r80?
- what is IGNORE_HELPER_CALL?
- take care when printing addresses. 0x%08lx won't work portably.
"0x%s", paddr (addr)" works better.
I'll look at ip2k-registers.h, remote-ip2k* later (I've got an OC target
to help with first). I've also, unfortunatly, put this out just as the
last of the frame overhaul goes in.
Andrew
Attachment:
gdb-ip2k.tar.gz
Description: application/gzip