www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1999/12/15/04:26:41

Date: Wed, 15 Dec 1999 09:20:26 +0200 (IST)
From: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>
X-Sender: eliz AT is
To: Michael Abbott aka frEk <20014670 AT snetch DOT cpg DOT com DOT au>
cc: DJGPP Mailing List <djgpp AT delorie DOT com>
Subject: Re: Compiler Source [OT]
In-Reply-To: <38571CDD.E6514FF3@snetch.cpg.com.au>
Message-ID: <Pine.SUN.3.91.991215092007.18491P-100000@is>
MIME-Version: 1.0
Reply-To: djgpp AT delorie DOT com
X-Mailing-List: djgpp AT delorie DOT com
X-Unsubscribes-To: listserv AT delorie DOT com

On Wed, 15 Dec 1999, Michael Abbott aka frEk wrote:

> GCC is great and I've been looking through the source to figure out
> where to begin (tho' it's too hefty for me at the moment) and since some
> of the people on this list would have a good idea of the internals of
> compilers, where would I find anything on compiler design? Any simple
> compilers (it doesn't necessarily have to be C/++ at the moment) or
> papers / documents or anything? Or maybe just a pointer to a useful
> newsgroup, etc.

I would suggest to start with something simpler that an
industry-strength compiler such as GCC.  A real-life compiler, and a
highly-portable one on top of that, has lots of gory details to sort
out, and that usually completely overwhelms someone who needs to learn
the basics.  Also, lots of GCC is about code optimizations, which is
probably irrelevant for you at this stage.

A better way would be to find a simpler language.  Things that come to
mind are Gawk and GNU bc, both available in DJGPP ports.

There was once a book called "The Unix Programming Environment" (by
Kernighan and Pike, I think) which had a chapter on developing a
calculator using Lex and Yacc.  If you can still find that book, that
would be a good beginning.  There are a couple of other books that
teach compiler construction using these tools as well.

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019