Nick Hilliard suggested:
> The bottom line is that gcc is not a particularly good optimising
> compiler, to say the least.
<snip>
> As far as speed is concerned, I've heard figures of 15% improvement
> being mentioned. It certainly wouldn't surprise me if it were higher
> for FP operations - which is another area where gcc is particularly
> awful.
It reminds me of a useful tip a computer science lecturer once gave me: fix
the algorithm first.
Using the right algorithm can increase speeds 2,5,10,100 times. Only once
you have run out of options should you think about using a compiler, or
faster hardware, to improve performance.
On the PPC vs Intel issue, I was also surprised by the results. They would
seem to indicate there is something wrong with the machine architecture as
the PPC chip should do integer and floating point math at least as well as
an equivalent MHz Pentium. I have had experiences in the past where two bits
of very fast hardware work slowly when put together. It usually seems to be
some kind of timing issue, similar to standing waves for this that remember
first year physics. I suspect this is a similar issue.
Or maybe the test was run using a program compiled for Intel and being
emulated on the PPC? :)
But the real question is: what kind of number crunching do you want to do?
If it is the hard core mathematical modelling that this usually entails,
then an Intel chip is usually the best option. Not because Intel is faster,
but because you should be able to replace the chip you bought with one that
is 50% faster for half the price a year later. (Somewhat exaggerated, I
know.)
You may also want to use a specialised chip instead. For example DSP's are
usually much better if you are doing a lot of FFT's as they are optimised
for the bulk move and array arithmetic.
On the choice of OS: it might be heresy but DOS could be the best option.
Multithreaded applications running in protected mode will usually incurr
some performance hit. The nice thing about linux is you can tune it to
reduce the amount of overhead .And you can kill all those other services
that you do not really need. Can one compile Linux to run completely in real
mode?
Personally I would love to have an 8-way Sun Ultra III to do my computation
for me, but not if I had to pay for it.
- Matthew
_________________________________________________________
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.yahoo.com
Maintained by the ILUG website team. The aim of Linux.ie is to
support and help commercial and private users of Linux in Ireland. You can
display ILUG news in your own webpages, read backend
information to find out how. Networking services kindly provided by HEAnet, server kindly donated by
Dell. Linux is a trademark of Linus Torvalds,
used with permission. No penguins were harmed in the production or maintenance
of this highly praised website. Looking for the
Indian Linux Users' Group? Try here. If you've read all this and aren't a lawyer: you should be!