From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 5377 invoked by alias); 17 Dec 2001 23:54:04 -0000 Mailing-List: contact gcc-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-owner@gcc.gnu.org Received: (qmail 5111 invoked from network); 17 Dec 2001 23:52:46 -0000 Received: from unknown (HELO mail.oek.dk) (195.215.62.2) by sources.redhat.com with SMTP; 17 Dec 2001 23:52:46 -0000 Received: from k403b.oek.dk ([10.211.4.26] helo=AMADEUS2) by mail.oek.dk with smtp (Exim 3.12 #1 (Debian)) id 16G7YU-0003ll-00; Tue, 18 Dec 2001 00:52:22 +0100 Message-ID: <00e501c18755$dd184610$d26afea9@AMADEUS2> From: "David Rasmussen" To: "mike stump" , References: <200112172321.PAA11826@kankakee.wrs.com> Subject: Re: How to understand gcc Date: Mon, 17 Dec 2001 16:20:00 -0000 MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2600.0000 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2600.0000 X-SW-Source: 2001-12/txt/msg00959.txt.bz2 ----- Original Message ----- From: "mike stump" To: ; Sent: Tuesday, December 18, 2001 12:21 AM Subject: Re: How to understand gcc > I think you can get answers as varied as people are. I'll just toss > out a few quick things that can keep you busy for 5 years learning. > > > From: "David Rasmussen" > > To: > > Date: Mon, 17 Dec 2001 23:51:19 +0100 > > > How can I learn how gcc works? > > :-) I like simple, to the point questions that have simple answers. > Unfortunately, yours is not. > I know :) > > I have taken one compiler course at my university, > > Good first step. In addition, you can take advanced algorithms > classes, theory classes... You can also go to the library and find I have taken a lot of courses in these areas. I study computer science and math. > books on compilers and languages and read them all. > OK, which books? Some are better than others, I gather. "Modern Compiler Implementation in ML" is not a good book, as aren't the others the author has done, for other implementation languages. > > and I own the "Dragon book" > > I'd recommend reading and understanding it, if you haven't yet. :-) > I have read and understood it. Of course, reading this book again wouldn't hurt. > > But really, I would like to have some sort of general understanding > > about the design of gcc, > > You didn't mention if you had read the gcc manual, see our web site, > under documentation, and manual. If you have not, you should. After > that, please read the comments in the code, after that please read the > code. After that, try fixing 100 bugs or doing a port. Your > understanding will improve when trying to fix bugs or while doing a > port. > I haven't done all of those things. Things for me to do... :) > Also helpful, write an interpreter and compiler from the ground up. > I have done that. In fact I have written a couple for assignments in various courses, but the results were quite "messy". I would like to have a book that I could read and do excercises from, that would help me build a good compiler with a nice design. > Lather, rinse, repeat. :) /David