` Printed Icetips Article

Icetips Article



Par2: FileBuffers for ASCII files
1998-11-02 -- John Longarrow
 
> Now, what I'm driving at is:  Are there any rule of thumbs here to
> calculate the size of the buffer size?  And why this drastic
> difference between the 16 and 32bit drivers?

(Performance with buffers=5000 is worse in 32 bit than 16 bit and performance
improves when buffers is set to 50; record length is 4096.)

From what I understant, when you set FILEBUFFERS=5000 with a 4K record
you are telling the driver to allocate 2 MEG per file to I/O buffering.
With tiny files this is WAY overkill, and I'd say use DIRECTORY() to
grab the file size. Then I'd SEND(FILEBUFFERS=(FileSize/RecordLength))
to the driver when accessing. I'm not sure if you can do this with the
ASCII driver. If it doesn't, I'd play around with how many buffers to
set based on expected file size. If you expect the files are going to be
small, set a small number. Otherwise go with a big one. Then again, I
think you alread demonstrated that!



Printed November 23, 2024, 11:13 pm
This article has been viewed/printed 35255 times.