Re: Microcontroller Compilers (C)

Klaus Rotter <rotter@touch.rotters.de>
15 Feb 2001 00:33:05 -0500

          From comp.compilers

Related articles
Microcontroller Compilers (C) mobius@news.eecs.umich.edu (2001-02-12)
Re: Microcontroller Compilers (C) jsgray@acm.org (Jan Gray) (2001-02-15)
Re: Microcontroller Compilers (C) rotter@touch.rotters.de (Klaus Rotter) (2001-02-15)
Re: Microcontroller Compilers (C) nej22@cl.cam.ac.uk (2001-02-15)
Re: Microcontroller Compilers (C) kyle_hayes@pacbell.net (Kyle) (2001-02-15)
Re: Microcontroller Compilers (C) vbdis@aol.com (2001-02-15)
Re: Microcontroller Compilers (C) rpgurd@archelon.com (Preston Gurd) (2001-02-15)
Re: Microcontroller Compilers (C) qarnos@ozemail.com.au (QarnoS) (2001-02-15)
Re: Microcontroller Compilers (C) henry@spsystems.net (2001-02-15)
[5 later articles]
| List of all articles for this month |
From: Klaus Rotter <rotter@touch.rotters.de>
Newsgroups: comp.compilers
Date: 15 Feb 2001 00:33:05 -0500
Organization: Rotter GbR
References: 01-02-046
Keywords: C
Posted-Date: 15 Feb 2001 00:33:05 EST

Matt Guthaus <mobius@news.eecs.umich.edu> wrote:
> I've been looking at GCC (Using and Porting the GNU Compiler Collection)
> and LCC. However, it seems that neither of these compilers is well adapted
> to 8- or 16-bit microcontrollers. GCC has only two 16-bit machine definition
> files (PDP11 and dsp16xx) and LCC has none.


Please look at the actual developers verfsion of gcc, it's called
egcs. There is a well done port of gcc to Atmels 8-bit uC AVR. There
exsits also a port of gcc to Motorolas 68HC11 and 68HC12. Besides
that, Imagecraft uses the lcc core for producing compilers for both
AVR and HC11.


> What would people recommend for the fastest way to get a prototype
> compiler working? GCC or LCC? Another compiler with a portable
> backend?


If your CPUs contain a lot of general purpose registers and it is
using a more or less linear adress space, I think a port could be
quickly done with both compilers. GCC is more complete, you get also
C++ for little cost. Please remember you also need an assembler and
linker and porting binutils is IMHO not as easy as porting gcc
itself. LCC is the better way if you want to modify the compiler
itself, because IMHO it is better documented.
--
  Klaus Rotter * mailto:klaus@rotters.de


Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.