stdio performance in tango, stdlib, and perl

Andrei Alexandrescu (See Website For Email) SeeWebsiteForEmail at erdani.org
Thu Mar 22 09:38:05 PDT 2007


Sean Kelly wrote:
> Andrei Alexandrescu (See Website For Email) wrote:
>> kris wrote:
>>>
>>> That aside, tango.io appears to be fast enough and simple enough. The 
>>> fastest in this case, even, assuming we do something useful about the 
>>> CR chop, .newline is adjusted, or "\n" is used instead ;)
>>
>> Oh, but I forgot it's cheating: uses read/write so it's incompatible 
>> with C's stdio, which phobos is.
> 
> If I understand you correctly, you're saying that all IO packages must 
> go through the standard C library so they stay in sync with the C IO 
> routines?  What is the point of read/write, ReadFile/WriteFile, etc, then?

I think for stdio, going through the standard C library would be very 
advisable. If, on the other hand, a library chooses to implement a file 
abstraction not exposing FILE*, it could use whichever means.

Andrei



More information about the Digitalmars-d mailing list