Mail Archives: djgpp/1996/06/16/03:21:11
On Thu, 13 Jun 1996, Shawn Hargreaves wrote:
> I think you people are seriously underestimating the power of gcc's
> optimiser. It is _good_ :-) Tricks like this may occasionally gain a slight
> speed increase, but in most cases gcc will do them for you if you just
> write your loop in the simple and obvious way. Making something this
> complicated can even be counterproductive: it obscures what you are
> trying to do, so the optimiser is less likely to figure out ways to make it
> faster.
The usual way to optimise the program is to make it work right, then to
profile it, and only *then* to optimise the fragments that appear as
``hot spots'' in the profile.
> You wouldn't be an ex-Borland user, by any chance? I notice people who
> have used Borland usually have a hard time trusting the compiler to produce
> good code without lots of help :-)
Even this seems to be not true since BC 3.x.
- Raw text -