Marc:
If you're in the mood for adding specializations to the compiler, please consider the approach to read-char and write-char in
<https://webmail.iro.umontreal.ca/pipermail/gambit-list/2007-February/ 001135.html>
<https://webmail.iro.umontreal.ca/pipermail/gambit-list/2007-February/ 001130.html>
and especially
<https://webmail.iro.umontreal.ca/pipermail/gambit-list/2007-February/ 001140.html>
I think character-based IO will probably end up being just about as fast as in C with this approach.
Brad