This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: porting GCC & GCC backends
- From: Paul Brook <paul at codesourcery dot com>
- To: gcc at gcc dot gnu dot org
- Cc: "Dave Korn" <dave dot korn at artimi dot com>, "'max blomme'" <mblomme at rumbledev dot com>
- Date: Tue, 26 Sep 2006 20:21:46 +0100
- Subject: Re: porting GCC & GCC backends
- References: <002901c6e19f$48fc9400$a501a8c0@CAM.ARTIMI.COM>
On Tuesday 26 September 2006 20:09, Dave Korn wrote:
> On 26 September 2006 20:01, max blomme wrote:
> > I'm attempting to port GCC to our companys 32bit microprocessor, and I'm
> > a bit overwhelmed.
> >
> > Looking through some of the documentation (there's quite a lot of it!) I
> > can't seem to find the answers to a few questions. Pardon me if they
> > seem basic and obvious.
> >
> > We already have an assembler and linker for the processor. Should I (or
> > can I) use them as the back end of GCC?
>
> Yes, you can. Gcc is designed to interoperate with system-native
> toolchains whereever possible.
Depending how crappy the existing assembler/linker are it may be easier to do
a gas/binutils/ld ELF port. Non-elf ports are generally a pain and I'd advise
avoiding them wherever possible.
You can always write a postlinker to convert an elf image into whatever format
your loader is expecting. This is what uClinux and SymbianOS do.
Paul