Related articles |
---|
Re: Architecture description languages for compilers? pardo@cs.washington.edu (1993-01-28) |
Thompson's 2c vs. gcc mike@skinner.cs.uoregon.edu (Michael John Haertel) (1993-01-29) |
Re: Thompson's 2c vs. gcc preston@dawn.cs.rice.edu (1993-02-02) |
Re: Thompson's 2c vs. gcc mike@skinner.cs.uoregon.edu (Michael John Haertel) (1993-02-04) |
Re: Thompson's 2c vs. gcc jbuck@forney.berkeley.edu (1993-02-04) |
Re: Thompson's 2c vs. gcc pardo@cs.washington.edu (1993-02-05) |
Re: Thompson's 2c vs. gcc meissner@osf.org (1993-02-05) |
Newsgroups: | comp.compilers |
From: | Michael John Haertel <mike@skinner.cs.uoregon.edu> |
Keywords: | architecture, GCC |
Organization: | Compilers Central |
References: | 93-01-205 |
Date: | Fri, 29 Jan 1993 04:41:12 GMT |
Pardo wrote:
>It is an amusing exercise to compare the listed md sizes for the Thompson
>compiler to the GCC md sizes for the same machines. I can't say whether
>the code is comparable: Thompson claims the compile time is half that of
>GCC and run time is 75% that of GCC, but it shows only slightly better run
>times than lcc, and a previous comp.compilers article said lcc was
>substantially worse than GCC.
I've used 2c. My experience is that gcc produces better code, contrary to
Thompson's claim. He most likely forgot to turn on -O with gcc. Without
-O, gcc produces really pessimal code, considerably slower than pcc
without -O for example.
The gcc source code (currently ~200,000 lines for the machine independent
part only, not counting the C++ and ObjC front ends) is more than 10 times
the size of the 2c source code. I would not say that gcc produces 10
times better code. Perhaps 10% better. This may be another case of 90%
of the benefit for 10% of the work. In addition, 2c compiles much faster.
Thompson's claim that 2c typically compiles in 50% of the time gcc takes
is probably an understatement, in fact. 2c is the most nearly I/O-bound
compiler I've ever used.
--
Return to the
comp.compilers page.
Search the
comp.compilers archives again.