on most implementations, cmp has two getchars (or getc's) in the inner loop. we got a factor of five improvement by reading in blocks and using memcmp.