BufferedInputstream performance
Hi
I am using BufferedInputStream to load in a file. Apparently i, get slightly lesser performance the higher i set my buffer. Why is that? There is approx. a 50 sec difference on 632 Mb file when I change the buffer from 2 Kb to 10 Mb....This seems very strange
Re: BufferedInputstream performance
The buffer is the temporary storage used in the copy iteration. When you increase the size of the buffer, you decrease the big O
Re: BufferedInputstream performance
how is that, and by how much? Don't you mean increase big O?
Re: BufferedInputstream performance
calculate how many buffers does it take to copy the entire file,.. the resulting number is the number of loops used in the copy process. Therefore, the larger the temporary storage (buffer) is the less loops you'll need to have. That's why enlarging buffer decreases the time
Any Questions?
Re: BufferedInputstream performance
Enlarging the buffer increases the copy time. Thats what is frustating me
Re: BufferedInputstream performance
"The buffer size specified should be a reasonable size so that your process will not run out of nonpaged pool, but it should also be large enough to accommodate typical requests." from MSDN Knowledge Base