On Mon, 21 Jun 2010 04:34:40 +0100, Steven D'Aprano <steve-remove-t...@cybersource.com.au> wrote:

On Sun, 20 Jun 2010 22:45:14 +0100, Rhodri James wrote:

No.  Modern C compilers often produce very good machine code, but the
best hand-written assembly code will be better.  I can usually write
*very* marginally better code than GCC achieves at work, though 99% of
the time I don't because it would be a maintenance nightmare.

Not that I don't believe you, but that is an extraordinary claim that
would require more evidence than just "Hey, some guy on the Internet
reckons his assembly code can regularly out-perform optimizing C
compilers" before I will change my opinion *wink*

Fairy 'nuff. In this case it's a matter of having a simple processor and knowing a trick or two that our in-house compiler apparently doesn't. Or didn't, since it has improved recently. Oh, and having done this for a decade or two :-)

But like we've been agreeing, most of the time knocking an instruction or two out of a function isn't worth the effort.

--
Rhodri James *-* Wildebeeste Herder to the Masses
--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to