Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Programming > Compilers > Re: Bootstrapin...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 8 of 19 Topic 2388 of 2472
Post > Topic >>

Re: Bootstraping compilers ?

by "Damian Thomas" <damian.thomas@[EMAIL PROTECTED] > Apr 18, 2008 at 08:46 AM

I think it is very beneficial to have a compiler be able to compile
itself.  It is an excellent test of the quality of the compiler.  (I
suggest starting with the C99 compiler written in C89, then migrate
the source to C99 when you have a functioning C99 compiler.)

Do not stop at simply compiling, but also using the resulting compiler to
compile itself again and again and again.
I suggest at least 3 generations of compiles.  Some say you should need 5
generations.
1st - finds compile-time errors
2nd - finds run-time errors
3rd - finds errors where the compiler ran improperly
4th - finds errors where the program ran correctly, but produced incorrect
results
5th - ?

The 3rd generation bugs are the hardest to find and diagnose.  I think
I've fixed one or two 4th generation bugs, but I've never seen a 5th
generation bug.  The exercise is well worth the effort.

Damian Thomas
Not speaking for my employer.


"Paulo Jorge de O. C. de Matos" <pocm@[EMAIL PROTECTED]
> wrote in message
> itself. gcc for example seems to do it, but is this good practice or
> should this always happen?
 




 19 Posts in Topic:
Bootstraping compilers ?
pocm@[EMAIL PROTECTED] (  2008-04-16 22:30:21 
Re: Bootstraping compilers ?
Chris Hills <chris@[EM  2008-04-18 11:45:12 
Re: Bootstraping compilers ?
pocm@[EMAIL PROTECTED] (  2008-04-22 00:07:22 
Re: Bootstraping compilers ?
David Spencer <spencer  2008-04-22 16:05:51 
Re: Bootstraping compilers ?
Hans-Peter Diettrich <  2008-04-22 20:07:33 
Re: Bootstraping compilers ?
=?ISO-8859-1?Q?Roland_Lei  2008-04-18 07:32:18 
Re: Bootstraping compilers ?
Marco van de Voort <ma  2008-04-18 19:32:59 
Re: Bootstraping compilers ?
"Damian Thomas"  2008-04-18 08:46:51 
Re: Bootstraping compilers ?
Marco van de Voort <ma  2008-04-18 19:38:29 
Re: Bootstraping compilers ?
"Christopher Glaeser  2008-04-19 23:42:06 
Re: Bootstraping compilers ?
Greg Lindahl <lindahl@  2008-04-18 14:13:55 
Re: Bootstraping compilers ?
torbenm@[EMAIL PROTECTED]  2008-04-21 10:35:52 
Re: Bootstraping compilers ?
Hans-Peter Diettrich <  2008-04-21 20:22:33 
Re: Bootstraping compilers ?
glen herrmannsfeldt <g  2008-04-21 21:18:53 
Re: Bootstraping compilers ?
glen herrmannsfeldt <g  2008-04-23 00:47:23 
Re: Fortran H, was Bootstraping compilers ?
"Comp.compilers"  2008-04-23 21:15:42 
Re: Fortran H, was Bootstraping compilers ?
=?ISO-8859-1?Q?J=FCrgen_K  2008-04-24 17:59:13 
Re: Fortran H, was Bootstraping compilers ?
glen herrmannsfeldt <g  2008-04-25 12:57:11 
Re: Fortran H, was Bootstraping compilers ?
glen herrmannsfeldt <g  2008-04-24 10:07:24 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Thu Jul 24 14:44:12 CDT 2008.