[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: gEDA-user: Icarus Verilog building from CVS

On Aug 6, 2004, at 11:44 PM, Al Davis wrote:
  Despite its popularity in the x86 world, GCC generates
horrid code on most, if not all, modern RISC platforms.  The
vendor-supplied compilers represent a tremendous amount of
in-the-know optimization and well-funded development that is
specific to their processor architectures.
  Really. :)

A few years ago, when I had access to a bunch of machines and a
bunch of compilers I tried ACS (precursor to Gnucap) on all of
them, with both GCC and the native one if possible.  The only
one that had any significant difference was Sun's.  The Sun
compiler was about 20% slower than GCC.  Has Sun's compiler
improved that much, or has GCC gotten that much worse?  Perhaps
Sun's compiler is better in some cases, and GCC better in
That's certainly possible. I have enough data points, however, that I don't even bother to install GCC on my Solaris systems anymore.

Now bear in mind, this is coming from a long-time GCC lover. Back In The Day(tm), I remember the very first thing to do on any new VAX system (running either VMS or UNIX) was to install GCC because it generated code that was much faster. The same went for M68K-based Suns...GCC produced much, much faster executables than the vendor-supplied compiler. That said, however, M68K and VAX are *extremely* CISC processors, designed to support compilers from the ground up. GCC's initial development was on processors like that...Very CISC architectures, and that's where it really seems to shine, even today.

(except, of course, for all the non-standard crap that it allows that many people unknowingly or uncaringly use, resulting in nonportable code)

But try it on a MIPS, SPARC, or other modern RISC or post-RISC architecture and things don't look so good. I've not done extensive reading on this, but I'm told that the inclusion of IBM's Haifa instruction scheduler in GCC a few years ago helped matters for RISC architectures, but the situation still gives me that "not so fresh" feeling.

Having said that...  Looking at the assembly code for C++, I see
that they are still missing some significant optimizations that
are not possible in C.
Hmm. I'm not much into C++ (I'm a C guy) so I can't speak to that. I'd love to see some examples though.


Dave McGuire "...it's a matter of how tightly
Cape Coral, FL you pull the zip-tie." -Nadine Miller