A new version, replacing the earlier. I tested this with a few applications, looks like for most of applications this has not much effect. However, wzebra proves that the effect can be enourmous on some. (And Simcity tellls that it can be negative on some applications :-(
Changelog:
- This patch speeds up applications reading files by small packets
- 4 static 512 byte buffers (can be defined for n * n buffers, see file.c)
- Buffer invalidation mechanism changed. With several buffers this *should*
fix the reported (thans to Tony Lambregts) slowdown on SIMCITY2000. I haven't got it, cannot test. Please test and see -debugmsg +file, it can give a hint about needed buffers and their sizes.
just a dumb question: shouldn't we better (for synchronous unix reads) convert the fd into a FILE* (cache those FILEs for a few streams, or all of them ?) and let libc do the buffering on file reading/writing ?
A+