
8 Chapter 1
Program 3: Early Morning Surprise
This program was written by a friend of mine while we were both at college. The
homework assignment was to write a matrix-multiply routine. However, the
function itself had to be written in assembly language. In order to make it run
as fast as possible, he used an algorithm that I designed, which vectorized the
matrix.
In order to test the system, he wrote a short test function in SAIL
2
. When
we tested the program, we got the wrong answers. Both of us poured over every
line of that code from 8:00 p.m. until 2:00 a.m. the next morning. When we
finally found the error, we both burst out laughing because ...