[R6RS] I/O issues
sperber at informatik.uni-tuebingen.de
Tue Aug 8 12:25:15 EDT 2006
William D Clinger <will at ccs.neu.edu> writes:
> Mike wrote:
>> I'll try again. Let's say your input port has a transcoder attached
>> to it, and you replace it by another one, by whatever means.
>> Supposedly, the new transcoder needs to start transcoding at the
>> beginning of the data that the program has read from the port.
Urks. I meant "end" or rather "at the beginning of" -> "just past".
> If you were saying that the new transcoder needs to start
> transcoding at the beginning of the data that has not yet
> been transcoded by the previous transcoder, it would make
> sense to me. But that interpretation does not affect the
> buffering of the underlying port. Since the standard
> transcoders you have proposed do not need any buffering
> of their own beyond a small finite-state machine, I don't
> see any performance problem with this model.
You may be able to perform the transcoding on a chunk of data in a
tight loop. (Also, other transcoders for stateful encodings might
need to buffer more, but I'd be happy to ignore that issue for the
time being.) This may be faster than calling into the state machine
from the outside every time.
> I offered to write benchmarks, but I thought the offer was
No. I said that a benchmark would be very helpful.
Cheers =8-} Mike
Friede, Völkerverständigung und überhaupt blabla
More information about the R6RS