Forum > General
Why FindAllFiles search for first time so long?
poiuyt555:
Hi.
I use FindAllFiles function to search for files.
When, for example, i try search for hole drive c:\
For the first time it searches fo 1,5 min, but in 2, 3 ... times it searches for 15 seconds
Why FindAllFiles search for first time so long?
How do that file search for first time take a 15 sec, not 1,5 minutes, it is possible?
mdalacu:
Because the OS caches the disk structure and the second run of FindAllFiles runs in memory (cache), not on disk.
BigChimp:
For some file systems there are alternative methodsd, like searching through the MFT blocks (IIRC) on an NTFS file system.
See the diskbuddy project I started on my bitbucket page (haven't converted anything yet, it's still the original Delphi code, but the MFT stuff may well work)
Of course, that's non-portable.
poiuyt555:
Thanks for answers.
But i don't understand: where i may see ' diskbuddy project I started on my bitbucket page' to view what is 'searching through the MFT blocks'?
BigChimp:
See my signature. Follow the link to my bitbucket projects. Go to the list of the repositories. Select diskbuddy...
As said, I haven't committed any changes yet, so the original Delphi source code from the original author is the same right now.
Navigation
[0] Message Index
[#] Next page