Re: To Richard Heathfield: enough's enough
From: dbtid (dbtid_at_dev.null.com)
Date: Thu, 01 Jan 2004 16:05:41 GMT
Edward G. Nilges wrote:
> The speed of the CPU trivializes programmers who obsess about
This is foolishness.
I worked on a system with 32 MB of RAM. Less than 16 MB of that was for
code and variables. That meant that more than 16 MB of it was space
that needed to be initialized to zero (system requirement -- so don't
make up excuses for why it *didn't* need to be done).
The people who wrote the operating system code for the implementation
for the processor we were using made a very foolish choice: they chose
to store BYTES of 0's instead of longs.
Can you guess how much faster my implementation was in which I used
multiple writes of longs vs a small loop that wrote only bytes?
Their version took 45 seconds. Mine took just under 15 seconds. And,
of course, I took care of the odd length issues that might be
I would not call this a trivial savings.
I bring this up to point out that looking at one series of instructions
to see what is happening is an important task for one who programs.
It's not a matter of microefficiency when you're working with large