Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 28 Apr 2001 14:12:09 +0200 (CEST)
From:      Bert Driehuis <driehuis@playbeing.org>
To:        stable@FreeBSD.ORG
Subject:   Re: Trouble with 4.3-RELEASE compiler
Message-ID:  <Pine.BSI.4.21.0104281356560.6127-100000@c1111.nl.compuware.com>
In-Reply-To: <3AEA96F8.C217C8BF@cvzoom.net>

next in thread | previous in thread | raw e-mail | index | archive | help
On Sat, 28 Apr 2001, Donn Miller wrote:

>                                                            If
> you want to make a program run faster, you've got to write implement
> better algorithms, and its as simple as that.  Beyond that, you'll just
> have to get faster HW.

This in general is true, but back in the days when GCC was a good C
compiler that also had a C++ like frontend, -O2 was safe, and if you saw
bugs at -O2, 99 out of a hundred times it was an actual bug in the code
that was exposed by the optimisation (usually an uninitialised
variable).

>                         I think most compilers have optimization bugs,
> because you use them with the understanding that they generate
> faster/smaller code at the expense of potential side effects.

There is no excuse for generating buggy code. The compiler has to take
valid C and produce object code that faithfully implements what the
source code describes. If the compiler does not do that, it's broken.

BSD/OS for the longest time shipped with two C compilers: gcc 1.42 and
gcc 2.x, and to this date, BSD/OS ships with a patched gcc in order to
take some broken optimisations out.

Cheers,

				-- Bert

-- 
Bert Driehuis -- driehuis@playbeing.org -- +31-20-3116119
If the only tool you've got is an axe, every problem looks like fun!


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-stable" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSI.4.21.0104281356560.6127-100000>