The previous implementation read the entire file into memory and then
processed it. This version uses reasonably-sized buffers and can handle
files of any size.
Since this new conversion code is a bit more complicated, a test suite
has been added which can be run on ordinary Unix systems.
GitOrigin-RevId: acc7be277103fad1da2d0ca16d1a84be11802fbf